$LOOPDEV not loop1
This commit is contained in:
parent
5f0627a5b3
commit
0d1e7a538b
@ -49,9 +49,9 @@ losetup $LOOPDEV $DISK
|
|||||||
|
|
||||||
kpartx -av $DISK
|
kpartx -av $DISK
|
||||||
|
|
||||||
mkfs.ext2 /dev/mapper/loop1p1
|
mkfs.ext2 /dev/mapper/${LOOPDEV}p1
|
||||||
|
|
||||||
mount /dev/mapper/loop1p1 /mnt
|
mount /dev/mapper/${LOOPDEV}p1 /mnt
|
||||||
|
|
||||||
echo "Installing main files."
|
echo "Installing main files."
|
||||||
cp -r $SRCDIR/hdd/* /mnt/
|
cp -r $SRCDIR/hdd/* /mnt/
|
||||||
@ -68,7 +68,7 @@ grub-install --target=i386-pc --boot-directory=/mnt/boot $LOOPDEV
|
|||||||
|
|
||||||
echo "Cleaning up"
|
echo "Cleaning up"
|
||||||
umount /mnt
|
umount /mnt
|
||||||
kpartx -d /dev/mapper/loop1p1
|
kpartx -d /dev/mapper/${LOOPDEV}p1
|
||||||
losetup -d $LOOPDEV
|
losetup -d $LOOPDEV
|
||||||
|
|
||||||
if [ -n "$SUDO_USER" ] ; then
|
if [ -n "$SUDO_USER" ] ; then
|
||||||
|
Loading…
Reference in New Issue
Block a user