From b4ce9b4030ed04a575466890d5caed9216f166a6 Mon Sep 17 00:00:00 2001 From: tranch Date: Sat, 25 Jul 2026 09:57:45 +0800 Subject: Normalize installer payload and host naming Use a formal local installer image tag and set aerocore-os as the default hostname in both the live image and installed target system. --- installer/Containerfile | 2 +- installer/build.sh | 18 +++++++++++++++++- 2 files changed, 18 insertions(+), 2 deletions(-) (limited to 'installer') diff --git a/installer/Containerfile b/installer/Containerfile index 34c5e28..fa5d731 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 INSTALL_IMAGE_PAYLOAD=ghcr.io/AeroCore-IO/aerocore-bazzite-image:stable +ARG INSTALL_IMAGE_PAYLOAD=ghcr.io/AeroCore-IO/aerocore-os:stable ARG INSTALL_IMAGE_PAYLOAD_ARCHIVE=/install-payload.oci FROM ${BASE_IMAGE} diff --git a/installer/build.sh b/installer/build.sh index aa30f42..c119dcc 100755 --- a/installer/build.sh +++ b/installer/build.sh @@ -111,6 +111,22 @@ df -h /var/tmp \${target_tmp} %end ostreecontainer --url=${INSTALL_IMAGE_PAYLOAD} --transport=containers-storage --no-signature-verification + +%post --nochroot --log=/tmp/aerocore-hostname.log +set -eux +target_root= +for root in /mnt/sysroot /mnt/sysimage /var/mnt/sysimage; do + if mountpoint -q \${root}; then + target_root=\${root} + break + fi +done +if [ x\${target_root} = x ]; then + echo No mounted target system found for hostname setup >&2 + exit 1 +fi +systemd-firstboot --root=\${target_root} --hostname=aerocore-os +%end EOF mkdir -p /usr/lib/bootc-image-builder @@ -146,5 +162,5 @@ mkdir -p /boot/efi/EFI/BOOT cp -v "${grubx64}" /boot/efi/EFI/BOOT/BOOTX64.EFI cp -v "${grubx64}" /boot/efi/EFI/BOOT/fbx64.efi -systemd-firstboot --timezone UTC +systemd-firstboot --hostname aerocore-os --timezone UTC dnf clean all -- cgit v1.2.3