Skip to content

Commit

Permalink
ENH: Validate and upload artifact from build
Browse files Browse the repository at this point in the history
Validates the qemu image then creates artifacts from the Github Actions
including the SHA256 (which OpenStack can use as part of the image
upload) as artifacts that stay around for ~1 week
  • Loading branch information
DavidFair committed Nov 12, 2024
1 parent 4aef55f commit 0cf0db7
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/amphora_builder.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,22 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Exec Amphora build
run: cd amphora-image-builder && ./build.sh

- name: Check image is valid
run: cd $GITHUB_WORKSPACE && 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
path: |
$GITHUB_WORKSPACE/output/amphora-x64-$(date +%Y-%m-%d)-haproxy.qcow2
$GITHUB_WORKSPACE/output/amphora-x64-$(date +%Y-%m-%d)-haproxy.qcow2.sha256
retention-days: 7

0 comments on commit 0cf0db7

Please sign in to comment.