This commit is contained in:
Marc Beninca 2024-11-12 10:11:35 +01:00
parent 44adf7cc8f
commit fbfb4c27e6
Signed by: marc.beninca
GPG key ID: 9C7613450C80C24F

View file

@ -8,8 +8,10 @@ if [ "${directory}" ] ; then
cd "overlay"
mkdir {lower,upper,work,mount}
if mount "${file}" "lower" ; then
mount -t "overlay" "overlay" "mount" \
mount \
-o lowerdir="lower",upperdir="upper",workdir="work"
-t "overlay" \
"overlay" "mount"
fi
cd ..
fi
@ -33,6 +35,7 @@ rmdir "overlay"
mr() {
local f
for f in "dev" "dev/pts" "proc" "sys" ; do
mount --bind "/${f}" "overlay/mount/${f}"
done
@ -50,6 +53,7 @@ chroot \
"
ur() {
local f
for f in "sys" "proc" "dev/pts" "dev" ; do
umount --lazy "overlay/mount/${f}"
done