Skip to content

Amphora image tweaks #63

Amphora image tweaks

Amphora image tweaks #63

name: Amphora Builder PR
on:
push:
branches:
- main
pull_request:
paths:
- ".github/workflows/amphora_builder.yml"
- "amphora-image-builder/**"
jobs:
shellcheck:
name: Shellcheck
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run ShellCheck
uses: ludeeus/action-shellcheck@master
with:
scandir: "./amphora-image-builder"
amphora-e2e:
name: Amphora E2E
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Exec Amphora build
run: |
cd $GITHUB_WORKSPACE/amphora-image-builder
./build.sh
sudo chown -R $USER:$USER $GITHUB_WORKSPACE/output
- name: Check image is valid
run: |
cd $GITHUB_WORKSPACE
sudo apt-get update && sudo apt-get install -y --no-install-recommends qemu-utils
qemu-img check output/amphora-x64-$(date +%Y-%m-%d)-haproxy.qcow2
- name: SHA256 image
run: |
cd $GITHUB_WORKSPACE
sha256sum output/amphora-x64-$(date +%Y-%m-%d)-haproxy.qcow2 > output/amphora-x64-$(date +%Y-%m-%d)-haproxy.qcow2.sha256
- name: Upload image
uses: actions/upload-artifact@v4
with:
name: amphora-image
if-no-files-found: error
path: output/*qcow2*
compression-level: 0 # qcow2 files are already compressed
retention-days: 7