mirror of
https://github.com/JasonN3/build-container-installer.git
synced 2025-12-25 19:07:54 +01:00
Merge branch 'main' into flatpak
This commit is contained in:
commit
6e7477cd52
6 changed files with 148 additions and 76 deletions
33
.github/workflows/build-and-test.yml
vendored
33
.github/workflows/build-and-test.yml
vendored
|
|
@ -49,7 +49,7 @@ jobs:
|
|||
with:
|
||||
containerfiles: Containerfile
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
|
||||
|
||||
- name: Push image
|
||||
uses: redhat-actions/push-to-registry@v2
|
||||
with:
|
||||
|
|
@ -58,7 +58,6 @@ jobs:
|
|||
username: ${{ github.actor }}
|
||||
password: ${{ github.token }}
|
||||
|
||||
|
||||
build-and-push-iso:
|
||||
runs-on: ubuntu-latest
|
||||
needs:
|
||||
|
|
@ -73,6 +72,9 @@ jobs:
|
|||
version:
|
||||
- 38
|
||||
- 39
|
||||
outputs:
|
||||
iso_name-38: ${{ steps.save_output.outputs.iso_name-38 }}
|
||||
iso_name-39: ${{ steps.save_output.outputs.iso_name-39 }}
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v4
|
||||
|
|
@ -93,6 +95,7 @@ jobs:
|
|||
|
||||
- name: Build ISO with new container
|
||||
uses: ./
|
||||
id: build
|
||||
with:
|
||||
arch: ${{ env.ARCH}}
|
||||
image_name: ${{ env.IMAGE_NAME}}
|
||||
|
|
@ -103,17 +106,22 @@ jobs:
|
|||
flatpak_remote_refs: ${{ env.FLATPAK_REMOTE_REFS }}
|
||||
secure_boot_key_url: ${{ env.SECURE_BOOT_KEY_URL }}
|
||||
enrollment_password: ${{ env.ENROLLMENT_PASSWORD }}
|
||||
iso_name: ${{ env.IMAGE_NAME }}-${{ env.IMAGE_TAG }}-${{ matrix.version }}.iso
|
||||
|
||||
- name: Rename ISO
|
||||
- name: Save output
|
||||
id: save_output
|
||||
shell: bash
|
||||
run: |
|
||||
mv build/deploy.iso build/${{ env.IMAGE_NAME }}-${{ env.IMAGE_TAG }}-${{ matrix.version }}.iso
|
||||
echo "iso_name-${{ matrix.version }}=${{ steps.build.outputs.iso_name}}" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Upload ISO as artifact
|
||||
id: upload
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ${{ env.IMAGE_NAME }}-${{ env.IMAGE_TAG }}-${{ matrix.version }}.iso
|
||||
path: build/*.iso
|
||||
name: ${{ steps.build.outputs.iso_name }}
|
||||
path: |
|
||||
${{ steps.build.outputs.iso_path }}
|
||||
${{ steps.build.outputs.iso_path }}-CHECKSUM
|
||||
if-no-files-found: error
|
||||
retention-days: 0
|
||||
compression-level: 0
|
||||
|
|
@ -142,7 +150,7 @@ jobs:
|
|||
- name: Ensure qemu is installed
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y qemu qemu-utils xorriso unzip qemu-system-x86 netcat socat jq isomd5sum ansible make
|
||||
sudo apt-get install -y qemu qemu-utils xorriso unzip qemu-system-x86 netcat socat jq isomd5sum ansible make coreutils
|
||||
|
||||
- name: Create disk
|
||||
run: |
|
||||
|
|
@ -151,14 +159,16 @@ jobs:
|
|||
- name: Download generated ISO
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: ${{ env.IMAGE_NAME }}-${{ env.IMAGE_TAG }}-${{ matrix.version }}.iso
|
||||
name: ${{ needs['build-and-push-iso']['outputs'][format('iso_name-{0}', matrix.version)] }}
|
||||
|
||||
- name: Verify ISO
|
||||
run: checkisomd5 ${{ env.IMAGE_NAME }}-${{ env.IMAGE_TAG }}-${{ matrix.version }}.iso
|
||||
run: |
|
||||
checkisomd5 ${{ needs['build-and-push-iso']['outputs'][format('iso_name-{0}', matrix.version)] }}
|
||||
sha256sum -c ${{ needs['build-and-push-iso']['outputs'][format('iso_name-{0}', matrix.version)] }}-CHECKSUM
|
||||
|
||||
- name: Run ISO checks
|
||||
run: |
|
||||
mv ${{ env.IMAGE_NAME }}-${{ env.IMAGE_TAG }}-${{ matrix.version }}.iso deploy.iso
|
||||
mv ${{ needs['build-and-push-iso']['outputs'][format('iso_name-{0}', matrix.version)] }} deploy.iso
|
||||
make test-iso VERSION=${{ matrix.version }} FLATPAK_REMOTE_REFS="${{ env.FLATPAK_REMOTE_REFS}}"
|
||||
|
||||
- name: Add Kickstart and Grub options to ISO
|
||||
|
|
@ -234,8 +244,5 @@ jobs:
|
|||
ansible_user: ${VM_USER}
|
||||
ansible_password: ${VM_PASS}
|
||||
EOF
|
||||
|
||||
cat ansible_inventory
|
||||
|
||||
make test-vm
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue