Update reusable-build-iso-anaconda.yml
This commit is contained in:
@@ -1,14 +1,8 @@
|
|||||||
name: Reusable Build
|
name: Reusable Build ISO
|
||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_call:
|
workflow_call:
|
||||||
inputs:
|
inputs:
|
||||||
image_version:
|
|
||||||
description: 'Which image version to build'
|
|
||||||
type: string
|
|
||||||
required: true
|
|
||||||
image_tag:
|
image_tag:
|
||||||
description: 'Image tag to build from'
|
|
||||||
type: string
|
type: string
|
||||||
default: stable
|
default: stable
|
||||||
upload_artifacts:
|
upload_artifacts:
|
||||||
@@ -17,78 +11,53 @@ on:
|
|||||||
upload_r2:
|
upload_r2:
|
||||||
type: boolean
|
type: boolean
|
||||||
default: true
|
default: true
|
||||||
|
secrets:
|
||||||
env:
|
R2_ACCESS_KEY_ID_2025:
|
||||||
IMAGE_REGISTRY: "ghcr.io/humocs-man"
|
required: false
|
||||||
IMAGE_NAME: "fluffy-pancake"
|
R2_SECRET_ACCESS_KEY_2025:
|
||||||
|
required: false
|
||||||
|
R2_ENDPOINT_2025:
|
||||||
|
required: false
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
determine-matrix:
|
|
||||||
name: Determine Build Matrix
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
outputs:
|
|
||||||
matrix: ${{ steps.set-matrix.outputs.matrix }}
|
|
||||||
steps:
|
|
||||||
- id: set-matrix
|
|
||||||
run: |
|
|
||||||
matrix='{"include":[
|
|
||||||
{"platform":"amd64","flavor":"cosmic","image_version":"stable"}
|
|
||||||
]}'
|
|
||||||
echo "matrix=$(echo "$matrix" | jq -c .)" >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
build:
|
build:
|
||||||
name: Build COSMIC Live ISO
|
name: Build ISO
|
||||||
runs-on: ubuntu-24.04
|
runs-on: ubuntu-24.04
|
||||||
needs: determine-matrix
|
|
||||||
strategy:
|
|
||||||
fail-fast: false
|
|
||||||
matrix: ${{ fromJSON(needs.determine-matrix.outputs.matrix) }}
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
packages: read
|
packages: read
|
||||||
id-token: write
|
id-token: write
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v5
|
- name: Checkout
|
||||||
with:
|
uses: actions/checkout@v5
|
||||||
submodules: recursive
|
|
||||||
|
|
||||||
- uses: extractions/setup-just@v3
|
- name: Create empty flatpak list
|
||||||
|
id: flatpaks
|
||||||
- name: Format image ref
|
|
||||||
id: image_ref
|
|
||||||
run: |
|
run: |
|
||||||
set -eoux pipefail
|
FILE="$(mktemp)"
|
||||||
image_name="${IMAGE_NAME}"
|
: > "$FILE"
|
||||||
image_ref="${IMAGE_REGISTRY}/${image_name}"
|
echo "file=$FILE" >> "$GITHUB_OUTPUT"
|
||||||
artifact_format="${image_name}-${{ matrix.image_version }}-cosmic-$(uname -m)"
|
|
||||||
echo "image_ref=$image_ref" >> $GITHUB_OUTPUT
|
|
||||||
echo "artifact_format=$artifact_format" >> $GITHUB_OUTPUT
|
|
||||||
echo "kargs=NONE" >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
- name: Build ISO
|
- name: Build ISO
|
||||||
id: build
|
id: build
|
||||||
uses: ublue-os/titanoboa@main
|
uses: ublue-os/titanoboa@main
|
||||||
with:
|
with:
|
||||||
image-ref: ${{ steps.image_ref.outputs.image_ref }}:${{ inputs.image_tag }}
|
image-ref: ghcr.io/humocs-man/fluffy-pancake:${{ inputs.image_tag }}
|
||||||
hook-post-rootfs: ${{ github.workspace }}/iso/enable_anaconda.sh
|
flatpaks-list: ${{ steps.flatpaks.outputs.file }}
|
||||||
kargs: ${{ steps.image_ref.outputs.kargs }}
|
hook-post-rootfs: ${{ github.workspace }}/iso_files/configure_iso_anaconda.sh
|
||||||
|
kargs: NONE
|
||||||
builder-distro: fedora
|
builder-distro: fedora
|
||||||
|
|
||||||
- name: Rename ISO
|
- name: Rename ISO
|
||||||
id: rename
|
|
||||||
env:
|
|
||||||
OUTPUT_PATH: ${{ steps.build.outputs.iso-dest }}
|
|
||||||
OUTPUT_NAME: ${{ steps.image_ref.outputs.artifact_format }}
|
|
||||||
run: |
|
run: |
|
||||||
mkdir -p output
|
mkdir -p output
|
||||||
mv "$OUTPUT_PATH" "output/${OUTPUT_NAME}.iso"
|
mv "${{ steps.build.outputs.iso-dest }}" output/fluffy-pancake-${{ inputs.image_tag }}.iso
|
||||||
sha256sum "output/${OUTPUT_NAME}.iso" > "output/${OUTPUT_NAME}.iso-CHECKSUM"
|
sha256sum output/*.iso | tee output/CHECKSUMS
|
||||||
echo "output_directory=$(realpath output)" >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
- name: Upload ISO Artifact
|
- name: Upload Artifacts
|
||||||
if: inputs.upload_artifacts
|
if: inputs.upload_artifacts
|
||||||
uses: actions/upload-artifact@v5
|
uses: actions/upload-artifact@v5
|
||||||
with:
|
with:
|
||||||
name: ${{ steps.image_ref.outputs.artifact_format }}
|
name: fluffy-pancake-iso
|
||||||
path: ${{ steps.rename.outputs.output_directory }}
|
path: output
|
||||||
|
|||||||
Reference in New Issue
Block a user