|
|
|
|
@ -187,8 +187,8 @@ echo "ln -s /proc/self/mounts /etc/mtab" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo "echo \"Done.\"" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo "echo \"\"" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo "echo \"Updating apt repositories inside chroot...\"" >> /mnt/setup-chroot.sh
|
|
|
|
|
#echo "apt update" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo "errors=`apt update 2\>\&1 1\>/dev/null`" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo "apt update" >> /mnt/setup-chroot.sh
|
|
|
|
|
#echo "errors=`apt update 2\>\&1 1\>/dev/null`" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo 'if ! [ "$?" = "0" ]; then '>> /mnt/setup-chroot.sh
|
|
|
|
|
echo " echo \"Failed to update apt repositories inside chroot - \$errors\"" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo " exit 1">> /mnt/setup-chroot.sh
|
|
|
|
|
@ -203,10 +203,10 @@ echo "apt install -y --no-install-recommends linux-image-generic" >> /mnt/setup-
|
|
|
|
|
echo "apt install -y vim bash screen tmux zfs-initramfs dosfstools openssh-server">> /mnt/setup-chroot.sh
|
|
|
|
|
i="0"
|
|
|
|
|
for disk in `echo "$disks"`; do
|
|
|
|
|
echo " echo \"mkdosfs -F 32 -s 1 -n EFI /dev/disk/by-id/${disk}-part2\"" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo " echo \"mkdir /boot/efi${i}\"" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo " echo \"echo PARTUUID=$(blkid -s PARTUUID -o value /dev/disk/by-id/${disk}-part2) /boot/efi${i} vfat nofail,x-systemd.device-timeout=0 0 1 >> /etc/fstab\"" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo " echo \"mount /boot/efi${i}\"" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo "mkdosfs -F 32 -s 1 -n EFI /dev/disk/by-id/${disk}-part2" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo "mkdir /boot/efi${i}" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo "echo PARTUUID=$(blkid -s PARTUUID -o value /dev/disk/by-id/${disk}-part2) /boot/efi${i} vfat nofail,x-systemd.device-timeout=0 0 1 >> /etc/fstab" >> /mnt/setup-chroot.sh
|
|
|
|
|
echo "mount /boot/efi${i}" >> /mnt/setup-chroot.sh
|
|
|
|
|
i=$((i + 1))
|
|
|
|
|
done
|
|
|
|
|
echo "apt install -y grub-efi-amd64-signed shim-signed" >> /mnt/setup-chroot.sh
|
|
|
|
|
|