me
/
guix
Archived
1
0
Fork 0

build: linux-container: Fix run-container.

This is a follow-up of 5316dfc0f1. Some users of
run-container may expect that the container is jailed, even if there are no
mounts. This is the case for some Guix tests.

* gnu/build/linux-container.scm (run-container): Do not jail the container
when the requested root is "/".
master
Mathieu Othacehe 2020-09-09 09:15:55 +02:00
parent cc6b1852e1
commit b3a83f1ece
No known key found for this signature in database
GPG Key ID: 8354763531769CA6
1 changed files with 2 additions and 2 deletions

View File

@ -243,8 +243,8 @@ that host UIDs (respectively GIDs) map to in the namespace."
(match (read child)
('ready
(purify-environment)
(when (and (not (null? mounts))
(memq 'mnt namespaces))
(when (and (memq 'mnt namespaces)
(not (string=? root "/")))
(catch #t
(lambda ()
(mount-file-systems root mounts