Enforce use of bind mount for /dev within chroot

The /dev/mapper directory created by devtmpfs lacked entry for
armbian-root thereby breaking the cryptsetup configuration generated
within initrd file. Use bind mount as that doesn't seem to suffer from
that issue.
This commit is contained in:
Gunjan Gupta
2023-07-21 04:33:10 +05:30
parent 37d79f1ee2
commit bc0e131747

View File

@@ -24,7 +24,7 @@ function mount_chroot() {
mount -t tmpfs -o "size=99%" tmpfs "${target}/run/user/0"
mount -t proc chproc "${target}"/proc
mount -t sysfs chsys "${target}"/sys
mount -t devtmpfs chdev "${target}"/dev || mount --bind /dev "${target}"/dev
mount --bind /dev "${target}"/dev
mount -t devpts chpts "${target}"/dev/pts || mount --bind /dev/pts "${target}"/dev/pts
}