Create build-installer-iso.yml workflow
Add GitHub Actions workflow to build installer ISO using Podman.
This commit is contained in:
@@ -1,5 +1,67 @@
|
||||
name: Build Installer ISO
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build-iso:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
packages: read
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4 # v4 ist aktuell und stabil
|
||||
|
||||
- name: Free disk space
|
||||
run: |
|
||||
sudo rm -rf /usr/share/dotnet
|
||||
sudo rm -rf /usr/local/lib/android
|
||||
sudo rm -rf /opt/ghc
|
||||
sudo rm -rf /opt/hostedtoolcache
|
||||
df -h
|
||||
|
||||
- name: Prepare output directory
|
||||
run: mkdir -p output
|
||||
|
||||
- name: Login to GHCR
|
||||
run: |
|
||||
# Wir nutzen hier kein sudo für den Login,
|
||||
# sondern authentifizieren den User-Space
|
||||
echo "${{ secrets.GITHUB_TOKEN }}" | podman login ghcr.io \
|
||||
-u ${{ github.actor }} --password-stdin
|
||||
|
||||
- name: Pull base image
|
||||
run: |
|
||||
# Pull ohne sudo, damit die Layer im User-Storage liegen
|
||||
podman pull ghcr.io/humocs-man/fluffy-pancake:stable
|
||||
|
||||
- name: Build ISO (Interactive Mode)
|
||||
run: |
|
||||
# Wir nutzen absolute Pfade mit ${{ github.workspace }}
|
||||
# WICHTIG: Der bootc-image-builder braucht Zugriff auf den lokalen Podman-Sockel
|
||||
# oder das Storage-Verzeichnis, um das Image zu finden.
|
||||
|
||||
sudo podman run --rm --privileged \
|
||||
-v ${{ github.workspace }}/iso/config.toml:/config.toml:ro \
|
||||
-v ${{ github.workspace }}/output:/output \
|
||||
-v /var/lib/containers/storage:/var/lib/containers/storage \
|
||||
quay.io/centos-bootc/bootc-image-builder:latest \
|
||||
--type anaconda-iso \
|
||||
--rootfs btrfs \
|
||||
--config /config.toml \
|
||||
--output /output/ \
|
||||
ghcr.io/humocs-man/fluffy-pancake:stable
|
||||
|
||||
- name: Upload ISO artifact
|
||||
uses: actions/upload-artifact@v4 # v4 ist die aktuelle Version
|
||||
with:
|
||||
name: installer-iso
|
||||
path: output/anaconda-iso/deploy.iso # Der Builder erstellt meist diese Unterstruktur
|
||||
if-no-files-found: errorname: Build Installer ISO
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
#push:
|
||||
|
||||
Reference in New Issue
Block a user