Set up a minimal /dev in chroots
Not bind-mounting the /dev from the host also solves the problem with /dev/shm being a symlink to something not in the chroot.
This commit is contained in:
parent
c9f6232304
commit
3fd01b171a
8 changed files with 40 additions and 17 deletions
|
|
@ -243,8 +243,7 @@ LocalStore::LocalStore(bool reserveSpace)
|
|||
Path gcRootsDir = settings.nixStateDir + "/gcroots";
|
||||
if (!pathExists(gcRootsDir)) {
|
||||
createDirs(gcRootsDir);
|
||||
if (symlink(profilesDir.c_str(), (gcRootsDir + "/profiles").c_str()) == -1)
|
||||
throw SysError(format("creating symlink to `%1%'") % profilesDir);
|
||||
createSymlink(profilesDir, gcRootsDir + "/profiles");
|
||||
}
|
||||
|
||||
checkStoreNotSymlink();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue