kernel bootparameter für verschlüsselten Boot vorbereitet

This commit is contained in:
eichehome 2023-03-30 11:12:24 +02:00
parent c8c5c19cd0
commit 38751ae4a7

View file

@ -246,6 +246,13 @@ if [[ $kernel == 3 || $kernel == 4 || $kernel == 5 ]]; then
fi fi
fi fi
cryptroot_name=$(grep "#\s/dev/mapper" /etc/fstab | head -n 1 | sed 's/#\s\/dev\/mapper\/\(.*\)\s.*/\1/')
cryptroot_device_name=$(grep "LABEL=EFI" /etc/fstab | sed 's/#\s\/dev\/\(.\{3\}\).*/\1/')
cryptroot_device_uuid=$(blkid -o value -s UUID /dev/"$cryptroot_device_name"2)
#sed -i "s/root=LABEL=arch/root=\/dev\/mapper\/$cryptroot_name rd.luks.name=$cryptroot_device_uuid=$cryptroot_name/" /boot/loader/entries/arch.conf
find . -type f -name arch\*.conf -exec sed -i "s/root=LABEL=arch/root=\/dev\/mapper\/$cryptroot_name rd.luks.name=$cryptroot_device_uuid=$cryptroot_name/" {} \;
useradd -mG wheel eichehome useradd -mG wheel eichehome
echo eichehome:testen | chpasswd echo eichehome:testen | chpasswd