Skip to content

Commit

Permalink
do not remove untagged images. keep dev images for a week.
Browse files Browse the repository at this point in the history
  • Loading branch information
shizunge committed Jan 20, 2024
1 parent 9886a9f commit 3935d4b
Showing 1 changed file with 13 additions and 12 deletions.
25 changes: 13 additions & 12 deletions .github/workflows/on-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -122,24 +122,25 @@ jobs:
uses: snok/container-retention-policy@v2
with:
image-names: gantry
cut-off: One month ago UTC
cut-off: One week ago UTC
account-type: personal
token: ${{ secrets.TOKEN_DELETE_GHCR_IMAGES }}
keep-at-least: 5
skip-tags: latest, development
filter-tags: "dev-*"
dry-run: False
- name: Delete untagged images
uses: snok/container-retention-policy@v2
with:
image-names: gantry
cut-off: 1 second ago UTC
account-type: personal
token: ${{ secrets.TOKEN_DELETE_GHCR_IMAGES }}
keep-at-least: 0
untagged-only: True
skip-tags: latest, development
dry-run: False
# # Untagged images could be the images for different OS/Arch. Do not delete them.
# - name: Delete untagged images
# uses: snok/container-retention-policy@v2
# with:
# image-names: gantry
# cut-off: 1 second ago UTC
# account-type: personal
# token: ${{ secrets.TOKEN_DELETE_GHCR_IMAGES }}
# keep-at-least: 0
# untagged-only: True
# skip-tags: latest, development
# dry-run: False

clean-ghcr-tests:
name: Delete old tests container images
Expand Down

0 comments on commit 3935d4b

Please sign in to comment.