Cleanup Untagged GHCR Images #1039
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
name: Cleanup Untagged GHCR Images | |
on: | |
workflow_dispatch: # Manually | |
schedule: | |
- cron: '0 0 * * *' # Every day at midnight | |
jobs: | |
purge-untagged-images: | |
name: Remove untagged images from ghcr.io | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
app: | |
- cb-metar | |
- ceil-vis | |
- ceil-vis15 | |
- ensemble | |
- home | |
- landuse | |
- precipAccum | |
- precipGauge | |
- precipitation1hr | |
- ptype | |
- radar | |
- scorecard | |
- surface | |
- surfrad | |
- upperair | |
steps: | |
- name: Delete image | |
uses: snok/[email protected] | |
with: | |
image-names: mats/development/${{ matrix.app }} | |
cut-off: 1 week ago MST | |
account-type: org | |
org-name: noaa-gsl | |
untagged-only: true | |
token: ${{ secrets.GHCR_CLEANUP_PAT }} |