diff options
author | Sven Gothel <[email protected]> | 2021-07-17 06:25:50 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2021-07-17 06:25:50 +0200 |
commit | 17e01431f059c24c1a11ff6a9b368ba5ac005227 (patch) | |
tree | 0516511f1da4687fd5c062cbcb53a75bb22edac6 | |
parent | d1513418918abc007b621bd1e2f8e6cb52851c8b (diff) |
multi-arch: Slim down grub.cfg on Debian amd64 target
-rwxr-xr-x | stage2/01-sys-tweaks/01-run.sh | 11 | ||||
-rw-r--r-- | stage2/01-sys-tweaks/files/grub/custom.cfg | 1 |
2 files changed, 9 insertions, 3 deletions
diff --git a/stage2/01-sys-tweaks/01-run.sh b/stage2/01-sys-tweaks/01-run.sh index c200ae2..92ed46f 100755 --- a/stage2/01-sys-tweaks/01-run.sh +++ b/stage2/01-sys-tweaks/01-run.sh @@ -153,8 +153,15 @@ if [ "${ROOTFS_RO}" = "1" ] ; then install -m 644 files/grub/custom.cfg "${ROOTFS_DIR}/boot/grub/custom.cfg" sed -i 's/sys_arm64_000/sys_${TARGET_ARCH}_000/g' "${ROOTFS_DIR}/boot/grub/custom.cfg" cp "${ROOTFS_DIR}/boot/grub/custom.cfg" "${ROOTFS_DIR}/boot/sys_${TARGET_ARCH}_000/" - sed -i 's/GRUB_DEFAULT=0/GRUB_DEFAULT=loop_rootfs/g' "${ROOTFS_DIR}/etc/default/grub" - #sed -i 's/GRUB_TIMEOUT=.*$/GRUB_TIMEOUT=0/g' "${ROOTFS_DIR}/etc/default/grub" + sed -i 's/GRUB_DEFAULT=.*$/GRUB_DEFAULT=loop_rootfs/g;s/GRUB_TIMEOUT=.*$/GRUB_TIMEOUT=0/g;s/#GRUB_TERMINAL=.*$/GRUB_TERMINAL=console/g;s/#GRUB_DISABLE_LINUX_UUID=.*$/GRUB_DISABLE_LINUX_UUID=true/g' \ + "${ROOTFS_DIR}/etc/default/grub" + echo "GRUB_DISABLE_LINUX_PARTUUID=true" >> "${ROOTFS_DIR}/etc/default/grub" + echo "GRUB_DISABLE_RECOVERY=true" >> "${ROOTFS_DIR}/etc/default/grub" + rm -f "${ROOTFS_DIR}/etc/grub.d/05_debian_theme" + rm -f "${ROOTFS_DIR}/etc/grub.d/10_linux" + rm -f "${ROOTFS_DIR}/etc/grub.d/20_linux_xen" + rm -f "${ROOTFS_DIR}/etc/grub.d/30_os-prober" + rm -f "${ROOTFS_DIR}/etc/grub.d/30_uefi-firmware" fi install -m 755 files/initramfs/loop_rootfs-premount "${ROOTFS_DIR}/etc/initramfs-tools/scripts/init-premount/loop_rootfs" diff --git a/stage2/01-sys-tweaks/files/grub/custom.cfg b/stage2/01-sys-tweaks/files/grub/custom.cfg index ac5c899..2de103d 100644 --- a/stage2/01-sys-tweaks/files/grub/custom.cfg +++ b/stage2/01-sys-tweaks/files/grub/custom.cfg @@ -1,5 +1,4 @@ menuentry 'Debian GNU/Linux loop_rootfs' --id loop_rootfs { - load_video insmod gzio insmod part_msdos insmod fat |