ghcr.io #256
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
# This workflow uses actions that are not certified by GitHub. | |
# They are provided by a third-party and are governed by | |
# separate terms of service, privacy policy, and support | |
# documentation. | |
name: ghcr.io | |
on: | |
schedule: | |
- cron: "21 21 * * *" | |
jobs: | |
clean-ghcr: | |
name: Delete old unused container images | |
runs-on: ubuntu-latest | |
permissions: | |
packages: write | |
steps: | |
- name: Delete 'PR' containers older than a week | |
uses: snok/[email protected] | |
with: | |
image-names: sensitive-data-archive | |
filter-tags: PR*,sha-* | |
skip-tags: v* | |
cut-off: A week ago UTC | |
account-type: org | |
org-name: ${{ github.repository_owner }} | |
keep-at-least: 1 | |
token: ${{ secrets.GHCR_TOKEN }} | |
timestamp-to-use: updated_at |