mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-24 16:03:23 +00:00
NixOS containers: Create /root with 700 permission
Systemd-nspawn creates /root with 755 permission if it doesn't exist, which is bad. So we have to create it ourselves before calling systemd-nspawn.
This commit is contained in:
parent
d5f63e9626
commit
3ca275d7ba
@ -194,7 +194,7 @@ in
|
||||
script =
|
||||
''
|
||||
mkdir -p -m 0755 "$root/etc" "$root/var/lib"
|
||||
mkdir -p -m 0700 "$root/var/lib/private"
|
||||
mkdir -p -m 0700 "$root/var/lib/private" "$root/root"
|
||||
if ! [ -e "$root/etc/os-release" ]; then
|
||||
touch "$root/etc/os-release"
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user