progress
This commit is contained in:
parent
e5b8ec5d60
commit
670dd61ce1
|
@ -28,53 +28,53 @@ config() {
|
||||||
|
|
||||||
if ! [ "${KEY_LANG}" == "en" ]; then
|
if ! [ "${KEY_LANG}" == "en" ]; then
|
||||||
if [ "${EFI}" == "1" ]; then
|
if [ "${EFI}" == "1" ]; then
|
||||||
VGUUID="$(vgdisplay |grep UUID|awk '{print $3}')"
|
#VGUUID="$(vgdisplay |grep UUID|awk '{print $3}')"
|
||||||
LVUUID="$(lvdisplay "/dev/mapper/vg_${TARGETNAME_UNDERSCORE}-root" |grep UUID|awk '{print $3}')"
|
#LVUUID="$(lvdisplay "/dev/mapper/vg_${TARGETNAME_UNDERSCORE}-root" |grep UUID|awk '{print $3}')"
|
||||||
rl="$(basename $(readlink "${TARGET_PHY_ID}-part${TARGET_PART}"))"
|
#rl="$(basename $(readlink "${TARGET_PHY_ID}-part${TARGET_PART}"))"
|
||||||
TMP="$(lsblk -o NAME,UUID -l|grep "${rl} " | awk '{print $2}')"
|
#TMP="$(lsblk -o NAME,UUID -l|grep "${rl} " | awk '{print $2}')"
|
||||||
CRYPTUUID="${TMP//-/}"
|
#CRYPTUUID="${TMP//-/}"
|
||||||
|
|
||||||
mkdir -p /boot/efi/EFI/void /boot/grub
|
#mkdir -p /boot/efi/EFI/void /boot/grub
|
||||||
grub-kbdcomp -o /boot/grub/${KEY_LANG}.gkb ${KEY_LANG}
|
#grub-kbdcomp -o /boot/grub/${KEY_LANG}.gkb ${KEY_LANG}
|
||||||
tar cf /boot/grub/memdisk.tar /boot/grub/${KEY_LANG}.gkb
|
#tar cf /boot/grub/memdisk.tar /boot/grub/${KEY_LANG}.gkb
|
||||||
|
|
||||||
#echo "set root=(memdisk)" > /boot/grub/early-grub.cfg
|
#echo "set root=(memdisk)" > /boot/grub/early-grub.cfg
|
||||||
#echo "set prefix=(\$root)/" >> /boot/grub/early-grub.cfg
|
#echo "set prefix=(\$root)/" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod gzio" >> /boot/grub/early-grub.cfg
|
#echo "insmod gzio" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod part_gpt" >> /boot/grub/early-grub.cfg
|
#echo "insmod part_gpt" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod cryptodisk" >> /boot/grub/early-grub.cfg
|
#echo "insmod cryptodisk" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod luks" >> /boot/grub/early-grub.cfg
|
#echo "insmod luks" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod gcry_rijndael" >> /boot/grub/early-grub.cfg
|
#echo "insmod gcry_rijndael" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod gcry_rijndael" >> /boot/grub/early-grub.cfg
|
#echo "insmod gcry_rijndael" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod gcry_sha256" >> /boot/grub/early-grub.cfg
|
#echo "insmod gcry_sha256" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod lvm" >> /boot/grub/early-grub.cfg
|
#echo "insmod lvm" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod btrfs" >> /boot/grub/early-grub.cfg
|
#echo "insmod btrfs" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod memdisk" >> /boot/grub/early-grub.cfg
|
#echo "insmod memdisk" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod tar" >> /boot/grub/early-grub.cfg
|
#echo "insmod tar" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod at_keyboard" >> /boot/grub/early-grub.cfg
|
#echo "insmod at_keyboard" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod keylayouts" >> /boot/grub/early-grub.cfg
|
#echo "insmod keylayouts" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod configfile" >> /boot/grub/early-grub.cfg
|
#echo "insmod configfile" >> /boot/grub/early-grub.cfg
|
||||||
echo "insmod all_video" >> /boot/grub/early-grub.cfg
|
#echo "insmod all_video" >> /boot/grub/early-grub.cfg
|
||||||
echo "terminal_input at_keyboard" >> /boot/grub/early-grub.cfg
|
#echo "terminal_input at_keyboard" >> /boot/grub/early-grub.cfg
|
||||||
echo "keymap /boot/grub/${KEY_LANG}.gkb" >> /boot/grub/early-grub.cfg
|
#echo "keymap /boot/grub/${KEY_LANG}.gkb" >> /boot/grub/early-grub.cfg
|
||||||
#echo "cryptomount -u ${CRYPTUUID}" >> /boot/grub/early-grub.cfg
|
#echo "cryptomount -u ${CRYPTUUID}" >> /boot/grub/early-grub.cfg
|
||||||
echo "cryptomount -a" >> /boot/grub/early-grub.cfg
|
#echo "cryptomount -a" >> /boot/grub/early-grub.cfg
|
||||||
echo "unset prefix" >> /boot/grub/early-grub.cfg
|
#echo "unset prefix" >> /boot/grub/early-grub.cfg
|
||||||
echo "set root='lvm/vg_${TARGETNAME_UNDERSCORE}-root'" >> /boot/grub/early-grub.cfg
|
#echo "set root='lvm/vg_${TARGETNAME_UNDERSCORE}-root'" >> /boot/grub/early-grub.cfg
|
||||||
#echo "set prefix=($root)/rootfs/boot/grub" >> /boot/grub/early-grub.cfg
|
#echo "set prefix=($root)/rootfs/boot/grub" >> /boot/grub/early-grub.cfg
|
||||||
echo "configfile (\$root)/rootfs/boot/grub.cfg" >> /boot/grub/early-grub.cfg
|
#echo "configfile (\$root)/rootfs/boot/grub.cfg" >> /boot/grub/early-grub.cfg
|
||||||
|
|
||||||
echo "#!/bin/bash" > /usr/bin/gen-grub
|
#echo "#!/bin/bash" > /usr/bin/gen-grub
|
||||||
echo "cd /" >> /usr/bin/gen-grub
|
#echo "cd /" >> /usr/bin/gen-grub
|
||||||
#echo "cp -rf /boot/grub/memdisk.tar /boot/grub/early-grub.cfg ." >> /usr/bin/gen-grub
|
#echo "cp -rf /boot/grub/memdisk.tar /boot/grub/early-grub.cfg ." >> /usr/bin/gen-grub
|
||||||
echo "grub-mkimage -c /boot/grub/early-grub.cfg -o grubx64_de.efi -O x86_64-efi -m /boot/grub/memdisk.tar gzio part_gpt cryptodisk luks gcry_rijndael gcry_rijndael gcry_sha256 lvm btrfs memdisk tar at_keyboard keylayouts configfile all_video" >> /usr/bin/gen-grub
|
#echo "grub-mkimage -c /boot/grub/early-grub.cfg -o grubx64_de.efi -O x86_64-efi -m /boot/grub/memdisk.tar gzio part_gpt cryptodisk luks gcry_rijndael gcry_rijndael gcry_sha256 lvm btrfs memdisk tar at_keyboard keylayouts configfile all_video" >> /usr/bin/gen-grub
|
||||||
echo "mv -f /grubx64_de.efi /boot/efi/EFI/void/grubx64_de.efi" >> /usr/bin/gen-grub
|
#echo "mv -f /grubx64_de.efi /boot/efi/EFI/void/grubx64_de.efi" >> /usr/bin/gen-grub
|
||||||
chmod +x /usr/bin/gen-grub
|
#chmod +x /usr/bin/gen-grub
|
||||||
gen-grub
|
#gen-grub
|
||||||
|
|
||||||
fi
|
fi
|
||||||
if ! grep -q rd.console.keymap /etc/default/grub; then
|
if ! grep -q rd.console.keymap /etc/default/grub; then
|
||||||
sed -i "/^GRUB_CMDLINE_LINUX_DEFAULT/s/=\"/=\" rd.vconsole.keymap=${L2} /" /etc/default/grub
|
sed -i "/^GRUB_CMDLINE_LINUX_DEFAULT/s/=\"/=\" rd.vconsole.keymap=${L2} /" /etc/default/grub
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user