Delete Old Packages #772
This file contains hidden or 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
| on: | |
| workflow_dispatch: | |
| push: | |
| paths: | |
| - '.github/workflows/delete-old-packages.yaml' | |
| schedule: | |
| # Runs "At 7:00am on every day of the week from Monday through Friday" | |
| - cron: '0 7 * * 1-5' | |
| name: Delete Old Packages | |
| env: | |
| NUM_OF_VERSIONS_TO_KEEP: 25 | |
| jobs: | |
| delete-old-packages: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| packages: write | |
| steps: | |
| - name: Delete packages | |
| uses: actions/delete-package-versions@v5 | |
| with: | |
| package-name: 'dotcom-rendering' | |
| package-type: 'container' | |
| min-versions-to-keep: ${{ env.NUM_OF_VERSIONS_TO_KEEP }} | |
| delete-only-untagged-versions: 'true' |