Skip to content

Prune ghcr.io container images #70

Prune ghcr.io container images

Prune ghcr.io container images #70

Workflow file for this run

name: Prune ghcr.io container images
on:
schedule:
# run once a day
- cron: '0 2 * * *'
workflow_dispatch:

Check failure on line 7 in .github/workflows/ghcr-prune.yml

View workflow run for this annotation

GitHub Actions / Prune ghcr.io container images

Invalid workflow file

The workflow is not valid. .github/workflows/ghcr-prune.yml (Line: 7, Col: 1): Unexpected value 'workflow_dispatch'
permissions: {}
jobs:
prune:
permissions:
packages: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- run: |
pip install requests
# remove containers older than 14 days and only generated by testing workflow
python .github/scripts/ghcr-prune.py --token ${{ secrets.GITHUB_TOKEN }} --org esmci --name cime --age 14 --filter sha- --filter-pr --untagged