[buildd-tools-devel] [PATCH] etc/setup.d/00check: Permit union chroots on the root directory
Geoffrey Thomas
geofft at MIT.EDU
Sat Nov 21 01:32:04 UTC 2009
From: Geoffrey Thomas <geofft at mit.edu>
It's only unsafe for the chroot directory to be the root directory if
we're not doing a union mount on top of it.
Note that aufs won't let you do a union mount of a parent directory of
/var/lib/schroot/union/overlay, so you'll need to make that directory a
separate filesystem, e.g., by mounting a tmpfs there.
Signed-off-by: Geoffrey Thomas <geofft at mit.edu>
---
etc/setup.d/00check | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/etc/setup.d/00check b/etc/setup.d/00check
index 494d62c..f62f068 100755
--- a/etc/setup.d/00check
+++ b/etc/setup.d/00check
@@ -131,7 +131,8 @@ esac
# toasted by accident.
if [ -z "$CHROOT_PATH" ] \
|| [ "$CHROOT_PATH" = "/" ] \
- || [ "$CHROOT_DIRECTORY" = "/" ] \
+ || ( [ -z "$CHROOT_UNION_TYPE" ] \
+ && [ "$CHROOT_DIRECTORY" = "/" ] ) \
|| [ "$CHROOT_UNION_OVERLAY_DIRECTORY" = "/" ]
then
echo "Invalid chroot mount path or directory"
--
1.6.3.3
More information about the Buildd-tools-devel
mailing list