Skip to content

Commit

Permalink
add clean job
Browse files Browse the repository at this point in the history
to remove untagged images from GitHub package registry
  • Loading branch information
peterstadler committed Oct 8, 2024
1 parent 43e5bf4 commit f869d94
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,3 +63,20 @@ jobs:
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

clean:
name: remove untagged images from Github package registry
runs-on: ubuntu-latest
permissions:
packages: write
needs: build
steps:
- name: ghcr.io cleanup action
uses: dataaxiom/ghcr-cleanup-action@v1
with:
package: odd-api
delete-untagged: true
dry-run: false
validate: true
older-than: 2 weeks
token: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit f869d94

Please sign in to comment.