From: Rene Mayrhofer Date: Mon, 22 Dec 2008 14:32:48 +0000 (+0100) Subject: Support further checks on loopback image and support skipping union mounts (Closes... X-Git-Tag: debian/1.154.4-1~1 X-Git-Url: http://git.grml.org/?a=commitdiff_plain;h=30b26980fceae5fa70e869e657b10f13e07c95b2;p=live-boot-grml.git Support further checks on loopback image and support skipping union mounts (Closes: #509446). --- diff --git a/scripts/live b/scripts/live index 2b8ff01..d06dd20 100755 --- a/scripts/live +++ b/scripts/live @@ -427,6 +427,11 @@ Arguments () export PLAIN_ROOT ;; + skipunion) + SKIP_UNION_MOUNTS="Yes" + export SKIP_UNION_MOUNTS + ;; + root=*) ROOT="${ARGUMENT#root=}" export ROOT @@ -1085,6 +1090,12 @@ setup_unionfs () do imagename=$(basename "${image}") + export image devname + maybe_break live-realpremount + log_begin_msg "Running /scripts/live-realpremount" + run_scripts /scripts/live-realpremount + log_end_msg + if [ -d "${image}" ] then # it is a plain directory: do nothing @@ -1242,8 +1253,12 @@ setup_unionfs () mount --bind ${exposedrootfs} ${rootmnt} || \ panic "bind mount of ${exposedrootfs} failed" - cow_dirs='/var/tmp /var/lock /var/run /var/log /var/spool - /home /var/lib/live' + if [ -z "${SKIP_UNION_MOUNTS}" ] + then + cow_dirs='/var/tmp /var/lock /var/run /var/log /var/spool /home /var/lib/live' + else + cow_dirs='' + fi for dir in ${cow_dirs}; do mkdir -p /cow${dir}