mirror of
https://github.com/NixOS/nix.git
synced 2024-11-21 22:32:26 +00:00
Oops - after chroot, the root is /
.
This commit is contained in:
parent
d6fd7eee56
commit
fdc5d1e894
@ -1971,7 +1971,7 @@ void LocalDerivationGoal::runChild()
|
||||
throw SysError("cannot remove real-root directory");
|
||||
|
||||
// Make build root read-only, so `mkdir /homeless-shelter` would fail.
|
||||
chmod_(chrootRootDir, 01555);
|
||||
chmod_("/", 0555);
|
||||
|
||||
/* Switch to the sandbox uid/gid in the user namespace,
|
||||
which corresponds to the build user or calling user in
|
||||
|
Loading…
Reference in New Issue
Block a user