Prune ghcr.io #296
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Prunes old aissemble-* containers, excluding all release tags and the two most recent non-release tags | |
name: Prune ghcr.io | |
on: | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
schedule: | |
- cron: "0 0 * * *" # every day at midnight | |
jobs: | |
prune_ghcr: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Prune ghcr | |
uses: dataaxiom/ghcr-cleanup-action@v1 | |
with: | |
log-level: info | |
packages: "^aissemble(?!.*?-chart$).*$" | |
expand-packages: true | |
token: ${{ secrets.GHCR_IO_TOKEN }} | |
exclude-tags: "^\\d+\\.\\d+\\.\\d+$" | |
use-regex: true | |
keep-n-tagged: 2 |