From 75919c6b2c8d227c5356db825d16e2ceded67575 Mon Sep 17 00:00:00 2001 From: tranch Date: Thu, 23 Jul 2026 01:06:50 +0800 Subject: ci: update live installer action inputs --- .github/workflows/build-live-installer.yml | 20 ++++++-------------- 1 file changed, 6 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build-live-installer.yml b/.github/workflows/build-live-installer.yml index 5993b2f..c685fd7 100644 --- a/.github/workflows/build-live-installer.yml +++ b/.github/workflows/build-live-installer.yml @@ -101,28 +101,20 @@ jobs: id: build uses: Zeglius/titanoboa@7737f4748458252ac827dca14b3d6dd09298472a # revamp-pr with: - arch: x86_64 - image_name: aerocore-live-payload - image_repo: localhost - variant: Kinoite - version: ${{ env.FEDORA_VERSION }} - image_tag: latest - iso_name: aerocore-os-${{ env.IMAGE_TAG }}-amd64.iso - enable_cache_dnf: "false" - enable_cache_skopeo: "false" - enable_flatpak_dependencies: "false" - additional_templates: /github/workspace/installer/lorax_templates/remove_root_password_prompt.tmpl /github/workspace/installer/lorax_templates/set_default_user.tmpl + image-ref: localhost/aerocore-live-payload:latest + iso-dest: ${{ github.workspace }}/output/aerocore-os-${{ env.IMAGE_TAG }}-amd64.iso - name: Display checksum run: | - cat "${{ steps.build.outputs.iso_path }}/${{ steps.build.outputs.iso_name }}-CHECKSUM" + iso_path="output/aerocore-os-${IMAGE_TAG}-amd64.iso" + sha256sum "${iso_path}" | tee "${iso_path}-CHECKSUM" - name: Upload ISO artifact uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7 with: name: aerocore-os-live-installer-${{ env.IMAGE_TAG }} path: | - ${{ steps.build.outputs.iso_path }}/${{ steps.build.outputs.iso_name }} - ${{ steps.build.outputs.iso_path }}/${{ steps.build.outputs.iso_name }}-CHECKSUM + output/aerocore-os-${{ env.IMAGE_TAG }}-amd64.iso + output/aerocore-os-${{ env.IMAGE_TAG }}-amd64.iso-CHECKSUM if-no-files-found: error compression-level: 0 -- cgit v1.2.3 From f114b3ff7f1924cb84d398d7c1054d930e74c043 Mon Sep 17 00:00:00 2001 From: tranch Date: Thu, 23 Jul 2026 14:30:04 +0800 Subject: feat: Adjust live installer build for consistent ISO naming Introduce an `ISO_FILE_TAG` environment variable to ensure consistent ISO filenames. This variable is set to 'testing' when on the testing branch, or uses the provided `image_tag` otherwise. This change affects the ISO destination path, checksum file generation, artifact upload naming, and the R2 upload. Additionally, prepare ISO and checksum files into a dedicated upload directory before uploading artifacts and to R2. This simplifies the artifact handling. --- .github/workflows/build-live-installer.yml | 47 +++++++++++++++++++++++++----- 1 file changed, 40 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build-live-installer.yml b/.github/workflows/build-live-installer.yml index c685fd7..4b8cb62 100644 --- a/.github/workflows/build-live-installer.yml +++ b/.github/workflows/build-live-installer.yml @@ -35,6 +35,7 @@ jobs: env: IMAGE_REGISTRY: ghcr.io/${{ github.repository_owner }} IMAGE_TAG: ${{ inputs.image_tag || 'latest' }} + ISO_FILE_TAG: ${{ github.ref_name == 'testing' && 'testing' || (inputs.image_tag || 'latest') }} # Keep these aligned with the Fedora major used by the target bazzite-deck base image. LIVE_BASE_IMAGE: quay.io/fedora/fedora-kinoite:43 FEDORA_VERSION: "43" @@ -102,19 +103,51 @@ jobs: uses: Zeglius/titanoboa@7737f4748458252ac827dca14b3d6dd09298472a # revamp-pr with: image-ref: localhost/aerocore-live-payload:latest - iso-dest: ${{ github.workspace }}/output/aerocore-os-${{ env.IMAGE_TAG }}-amd64.iso + iso-dest: ${{ github.workspace }}/output/aerocore-os-${{ env.ISO_FILE_TAG }}-amd64.iso - name: Display checksum run: | - iso_path="output/aerocore-os-${IMAGE_TAG}-amd64.iso" - sha256sum "${iso_path}" | tee "${iso_path}-CHECKSUM" + iso_path="output/aerocore-os-${ISO_FILE_TAG}-amd64.iso" + checksum_path="${iso_path}-CHECKSUM" + sha256sum "${iso_path}" | tee "${checksum_path}" + { + echo "# ISO Checksum (SHA256)" + echo + echo "ISO: $(basename "${iso_path}")" + echo + echo '```' + cat "${checksum_path}" + echo '```' + } >> "$GITHUB_STEP_SUMMARY" + + - name: Prepare ISO upload files + run: | + iso_path="output/aerocore-os-${ISO_FILE_TAG}-amd64.iso" + upload_dir="output/upload" + mkdir -p "${upload_dir}" + mv "${iso_path}" "${upload_dir}/" + mv "${iso_path}-CHECKSUM" "${upload_dir}/" - name: Upload ISO artifact uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7 with: - name: aerocore-os-live-installer-${{ env.IMAGE_TAG }} - path: | - output/aerocore-os-${{ env.IMAGE_TAG }}-amd64.iso - output/aerocore-os-${{ env.IMAGE_TAG }}-amd64.iso-CHECKSUM + name: aerocore-os-live-installer-${{ env.ISO_FILE_TAG }} + path: output/upload if-no-files-found: error compression-level: 0 + + - name: Upload ISO and checksum to R2 + if: github.ref_name == 'testing' || github.ref_name == 'main' + shell: bash + env: + RCLONE_CONFIG_R2_TYPE: s3 + RCLONE_CONFIG_R2_PROVIDER: Cloudflare + RCLONE_CONFIG_R2_ACCESS_KEY_ID: ${{ secrets.R2_ACCESS_KEY_ID }} + RCLONE_CONFIG_R2_SECRET_ACCESS_KEY: ${{ secrets.R2_SECRET_ACCESS_KEY }} + RCLONE_CONFIG_R2_REGION: auto + RCLONE_CONFIG_R2_ENDPOINT: ${{ secrets.R2_ENDPOINT }} + SOURCE_DIR: ${{ github.workspace }}/output/upload + run: | + sudo apt-get update + sudo apt-get install -y rclone + rclone copy "$SOURCE_DIR" R2:bazzite -- cgit v1.2.3