Skip to content

Commit d8a280d

Browse files
committed
Hide mdadm during image building
1 parent 068d61d commit d8a280d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

rootfs/make_rootfs.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,10 +141,9 @@ do_chroot() {
141141
mount -o bind /tmp "$DEST/tmp"
142142
chroot "$DEST" mount -t proc proc /proc
143143
chroot "$DEST" mount -t sysfs sys /sys
144+
chroot "$DEST" mount --bind /dev/null /proc/mdstat
144145
chroot "$DEST" $cmd
145-
chroot "$DEST" umount /sys
146-
chroot "$DEST" umount /proc
147-
umount "$DEST/tmp"
146+
chroot "$DEST" umount /sys /proc/mdstat /proc /tmp
148147
}
149148

150149
do_install() {
@@ -295,6 +294,7 @@ mkdir -p "$DEST/usr"
295294
rm -f "$DEST/usr/bin/qemu-arm-static"
296295
rm -f "$DEST/usr/bin/qemu-aarch64-static"
297296
rm -f "$DEST/usr/sbin/policy-rc.d"
297+
rm -f "$DEST/usr/local/bin/mdadm"
298298
rm -f "$DEST/var/lib/dbus/machine-id"
299299
rm -f "$DEST/SHA256SUMS"
300300

0 commit comments

Comments
 (0)