Skip to content
This repository has been archived by the owner on Aug 3, 2023. It is now read-only.

Delete old container images #202

Delete old container images

Delete old container images #202

name: Delete old container images
on:
workflow_dispatch:
schedule:
- cron: "0 6 * * *" # every day at 6 in the morning
jobs:
clean-ghcr:
name: Delete old unused container images
runs-on: ubuntu-latest
steps:
- name: Delete dev containers older than a week
uses: snok/container-retention-policy@v1.5.1
with:
image-names: epinio-ui
cut-off: A week ago UTC
account-type: org
org-name: epinio
keep-at-least: 1
filter-tags: v*-[0-9]*-g*
filter-include-untagged: true
token: ${{ secrets.IMG_CLEANUP_TOKEN }}
- name: Delete untagged containers older than a week
uses: snok/container-retention-policy@v1.5.1
with:
image-names: epinio-ui
cut-off: A week ago UTC
account-type: org
org-name: epinio
keep-at-least: 1
token: ${{ secrets.IMG_CLEANUP_TOKEN }}
untagged-only: true