diff options
Diffstat (limited to 'installer')
| -rw-r--r-- | installer/Containerfile | 2 | ||||
| -rwxr-xr-x | installer/build.sh | 18 | ||||
| -rwxr-xr-x | installer/configure-target-gpt-root.sh | 1 |
3 files changed, 19 insertions, 2 deletions
diff --git a/installer/Containerfile b/installer/Containerfile index 32b327e..a7f1d3b 100644 --- a/installer/Containerfile +++ b/installer/Containerfile @@ -2,7 +2,7 @@ # The image installed to disk is supplied separately as INSTALL_IMAGE_PAYLOAD. ARG BASE_IMAGE=ghcr.io/ublue-os/bazzite:stable -ARG IMAGE_VENDOR=AeroCore-IO +ARG IMAGE_VENDOR=aerocore-io ARG IMAGE_NAME=aerocore-os ARG INSTALL_IMAGE_PAYLOAD=ghcr.io/${IMAGE_VENDOR}/${IMAGE_NAME}:stable ARG INSTALL_IMAGE_PAYLOAD_ARCHIVE=/install-payload.oci diff --git a/installer/build.sh b/installer/build.sh index 937d324..e027bd6 100755 --- a/installer/build.sh +++ b/installer/build.sh @@ -158,6 +158,24 @@ fi /usr/libexec/aerocore-configure-target-gpt-root \${target_root} %end +# Do not let stale Fedora boot files from an earlier installation collide with +# the bootc payload being installed. This matches the upstream Bazzite +# installer behavior; other vendor EFI directories are left untouched. +%pre-install --erroronfail --log=/tmp/aerocore-efi-cleanup.log +set -eux +efi_root= +for root in /mnt/sysroot /mnt/sysimage /var/mnt/sysroot /var/mnt/sysimage; do + if mountpoint -q \${root}/boot/efi; then + efi_root=\${root}/boot/efi + break + fi +done +if [ x\${efi_root} = x ]; then + echo No mounted EFI system partition found for cleanup >&2 + exit 1 +fi +rm -rf \${efi_root}/EFI/fedora +%end ostreecontainer --url=${INSTALL_IMAGE_PAYLOAD} --transport=containers-storage --no-signature-verification # The local containers-storage deployment is intentionally unverified because diff --git a/installer/configure-target-gpt-root.sh b/installer/configure-target-gpt-root.sh index 470821e..6c1a2d1 100755 --- a/installer/configure-target-gpt-root.sh +++ b/installer/configure-target-gpt-root.sh @@ -17,7 +17,6 @@ if [[ ! "${source_device}" =~ ^/dev/ ]]; then source_maj_min="$(findmnt -no MAJ:MIN --target "${target_root}")" source_device="$(lsblk -nrpo NAME,MAJ:MIN | awk -v wanted="${source_maj_min}" '$2 == wanted { print $1; exit }')" fi - case "${source_device}" in /dev/*[0-9]) ;; *) |
