mirror of
https://github.com/BigfootACA/arch-image-builder.git
synced 2024-09-21 15:20:53 +08:00
builder: build: filesystem.py: allow add or remove files to /var
Signed-off-by: BigfootACA <bigfoot@classfun.cn>
This commit is contained in:
parent
37aed6dfee
commit
1e9877ff7e
@ -75,8 +75,9 @@ def check_allowed(path: str, action: str):
|
|||||||
Why these folder is writable
|
Why these folder is writable
|
||||||
1. /etc/ is used for administrator configs
|
1. /etc/ is used for administrator configs
|
||||||
2. /boot/ is used for system boot up, you can put bootloaders configs into this folder
|
2. /boot/ is used for system boot up, you can put bootloaders configs into this folder
|
||||||
|
3. /var/ is used for daemons runtime states
|
||||||
"""
|
"""
|
||||||
if not path.startswith(("/etc/", "/boot/")):
|
if not path.startswith(("/etc/", "/boot/", "/var/")):
|
||||||
raise ArchBuilderConfigError(f"{action} {path} is not allowed")
|
raise ArchBuilderConfigError(f"{action} {path} is not allowed")
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user