diff --git a/build.sh b/build.sh index d80c4e6..b895e12 100755 --- a/build.sh +++ b/build.sh @@ -67,11 +67,11 @@ function base_bootstrap() { $SUDO rm "${MOUNTPOINT}/etc/hostname" $SUDO rm "${MOUNTPOINT}/etc/apt/sources.list" if [[ -v LOOPDEV ]]; then + ROOTUUID=$($SUDO blkid -s UUID -o export "${LOOPDEV}p2" | grep UUID) + BOOTUUID=$($SUDO blkid -s UUID -o export "${LOOPDEV}p1" | grep UUID) + else ROOTUUID=/dev/mmcblk0p2 BOOTUUID=/dev/mmcblk0p1 - else - ROOTUUID=$($SUDO blkid -s UUID -o export "${LOOPDEV:-error}p2" | grep UUID) - BOOTUUID=$($SUDO blkid -s UUID -o export "${LOOPDEV:-error}p1" | grep UUID) fi echo "proc /proc proc defaults 0 0 $BOOTUUID /boot vfat defaults 0 2