Skip to content

Commit 0034bc0

Browse files
committed
sandbox: mount dev/shm
Some tools use this while building. E.g. the python multiprocessing library uses this for its locking mechanism.
1 parent f1d7cba commit 0034bc0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/namespace-sandbox/namespace-sandbox.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -431,6 +431,9 @@ static void SetupDevices() {
431431
CHECK_CALL(mount("devpts", "dev/pts", "devpts", MS_NOSUID | MS_NOEXEC, "ptmxmode=0666"));
432432
CHECK_CALL(symlink("pts/ptmx", "dev/ptmx"));
433433

434+
CreateTarget("dev/shm", true);
435+
CHECK_CALL(mount("tmpfs", "dev/shm", "tmpfs", MS_NOSUID | MS_NODEV, NULL));
436+
434437
CHECK_CALL(symlink("/proc/self/fd", "dev/fd"));
435438
}
436439

0 commit comments

Comments
 (0)