alpine: fix efinvram installation
This commit is contained in:
parent
5d5e94d05f
commit
6910bd8931
1 changed files with 16 additions and 12 deletions
|
@ -162,13 +162,6 @@ case "$BOOT_VIA" in
|
||||||
echo "UUID=$UUID_2 / ext4 defaults 0 1" >> ${rootfs_tmpdir}/etc/fstab
|
echo "UUID=$UUID_2 / ext4 defaults 0 1" >> ${rootfs_tmpdir}/etc/fstab
|
||||||
echo "UUID=$UUID_1 /boot vfat defaults 0 2" >> ${rootfs_tmpdir}/etc/fstab
|
echo "UUID=$UUID_1 /boot vfat defaults 0 2" >> ${rootfs_tmpdir}/etc/fstab
|
||||||
|
|
||||||
run_root grub-install --efi-directory=/boot --no-nvram
|
|
||||||
run_root mkdir /boot/EFI/boot
|
|
||||||
run_root cp /boot/EFI/alpine/grubx64.efi /boot/EFI/boot/bootx64.efi
|
|
||||||
run_root cp /boot/grub/grub.cfg /boot/EFI/boot/
|
|
||||||
sudo umount ${rootfs_tmpdir}/boot
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
# Actually do add us to the bios
|
# Actually do add us to the bios
|
||||||
if [ $BOOT_VIA = "efinvram" ]; then
|
if [ $BOOT_VIA = "efinvram" ]; then
|
||||||
|
@ -176,8 +169,19 @@ if [ $BOOT_VIA = "efinvram" ]; then
|
||||||
sudo mount --bind ${dir} ${rootfs_tmpdir}${dir}
|
sudo mount --bind ${dir} ${rootfs_tmpdir}${dir}
|
||||||
run_root apk add efibootmgr
|
run_root apk add efibootmgr
|
||||||
run_root grub-install --efi-directory=/boot
|
run_root grub-install --efi-directory=/boot
|
||||||
|
else
|
||||||
|
run_root grub-install --efi-directory=/boot --no-nvram
|
||||||
|
|
||||||
|
# FIX for some machines (?)
|
||||||
|
run_root mkdir /boot/EFI/boot
|
||||||
|
run_root cp /boot/EFI/alpine/grubx64.efi /boot/EFI/boot/bootx64.efi
|
||||||
|
run_root cp /boot/grub/grub.cfg /boot/EFI/boot/
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
sudo umount ${rootfs_tmpdir}/boot
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
|
||||||
# Debug
|
# Debug
|
||||||
run_root cat /etc/fstab
|
run_root cat /etc/fstab
|
||||||
|
|
Loading…
Reference in a new issue