projects
/
rrq
/
overlay-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
9225ced
)
sanity check before overlay
author
Ralph Ronnquist
<ralph.ronnquist@gmail.com>
Sat, 26 Mar 2022 12:20:21 +0000
(23:20 +1100)
committer
Ralph Ronnquist
<ralph.ronnquist@gmail.com>
Sat, 26 Mar 2022 12:20:21 +0000
(23:20 +1100)
functions
patch
|
blob
|
history
diff --git
a/functions
b/functions
index 8c1b45c048706c91a2923f451c5065040c0224f6..ab20d20ace23d5c7f3e265f4cf7d1d469479dd7b 100644
(file)
--- a/
functions
+++ b/
functions
@@
-89,13
+89,14
@@
setup_overlay() {
# LIVE is the same as LOWER then skip the overlay; just assume
# a proper chroot system exists at LIVE.
if [ "$LIVE" != "$LOWER" ] ; then
# LIVE is the same as LOWER then skip the overlay; just assume
# a proper chroot system exists at LIVE.
if [ "$LIVE" != "$LOWER" ] ; then
- # setup $UPPER/run
- mkdir -p "$UPPER/run"
- mount -t tmpfs -osize=100M tmpfs "$UPPER/run"
- mkdir -p "$UPPER/run/lock"
+ # sanity check
+ [ -d "$WORK" ] || die "WORK=$WORK is not a directory"
+ [ -d "$UPPER" ] || die "UPPER=$UPPER is not a directory"
+ [ -d "$LOWER" ] || die "LOWER=LOWPER is not a directory"
+ [ -d "$LIVE" ] || die "LOWER=LOWPER is not a directory"
# setup $UPPER/dev
mkdir -p "$UPPER/dev"
# setup $UPPER/dev
mkdir -p "$UPPER/dev"
- mount -t tmpfs -osize=
10
0M tmpfs "$UPPER/dev"
+ mount -t tmpfs -osize=
5
0M tmpfs "$UPPER/dev"
mknod -m 622 "$UPPER/dev/console" c 5 1
mknod -m 666 "$UPPER/dev/null" c 1 3
mknod -m 666 "$UPPER/dev/zero" c 1 5
mknod -m 622 "$UPPER/dev/console" c 5 1
mknod -m 666 "$UPPER/dev/null" c 1 3
mknod -m 666 "$UPPER/dev/zero" c 1 5