Fix non-crypto install
This commit is contained in:
parent
257067a67f
commit
5635e9efac
@ -9,6 +9,7 @@ read answer
|
||||
if [ "$answer" == "n" ] || [ "$answer" == "N" ]; then
|
||||
echo "~> There are close to no reasons to not do this, but hey, you're an adult."
|
||||
rootformat=${blockdevice}2
|
||||
didCrypt=0
|
||||
else
|
||||
echo "~> Formatting root (/) for crypto"
|
||||
cryptsetup -v luksFormat ${blockdevice}2
|
||||
@ -17,6 +18,7 @@ else
|
||||
echo "~> Open the crypt container"
|
||||
cryptsetup luksOpen ${blockdevice}2 cryptroot
|
||||
rootformat=/dev/mapper/cryptroot
|
||||
didCrypt=1
|
||||
fi
|
||||
|
||||
echo "~> Formatting $rootformat EXT4"
|
||||
|
@ -26,7 +26,10 @@ else
|
||||
arch-chroot /mnt grub-install --target=i386-pc /dev/*da
|
||||
fi
|
||||
|
||||
if [ "$didCrypt" -eq 1 ]; then
|
||||
echo "GRUB_CMDLINE_LINUX='cryptdevice=UUID=`blkid -o value ${blockdevice}2 | head -n 1`:cryptroot'" > /mnt/etc/default/grub
|
||||
fi
|
||||
|
||||
arch-chroot /mnt grub-mkconfig -o /boot/grub/grub.cfg
|
||||
|
||||
echo "~> Patching mkinitcpio.conf for encryption magic"
|
||||
|
Loading…
Reference in New Issue
Block a user