1
0
Fork 0

Rework cleanup

Makes cleanup run after all other steps regardless of success or
failure. Additionally removes resulting artifact.
This commit is contained in:
ver4a 2024-11-06 12:47:25 +01:00
parent 3cd85014e5
commit 02d8c30a0d

View file

@ -8,4 +8,5 @@ jobs:
- run: podman login -u ${{ vars.REGISTRY_USERNAME }} -p ${{ secrets.REGISTRY_PASSWORD }} ${{ vars.REGISTRY_DOMAIN }}
- run: podman build . --no-cache --pull=newer --squash-all -t ${{ vars.REGISTRY_DOMAIN }}/${{ vars.MAIN_IMAGE }}:40
- run: podman push ${{ vars.REGISTRY_DOMAIN }}/${{ vars.MAIN_IMAGE }}:40 ${{ vars.REGISTRY_DOMAIN }}/${{ vars.MAIN_IMAGE }}:40
- run: podman image prune -f
- if: '!cancelled()'
run: podman image rm -f ${{ vars.REGISTRY_DOMAIN }}/${{ vars.MAIN_IMAGE }}:40 && podman image prune -f