Skip to content

Commit 7dd9114

Browse files
committed
feat: clean up untagged images
Add GHA workflow that runs once a week on Sunday at midnight UTC and deletes all untagged images.
1 parent bba155c commit 7dd9114

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

.github/workflows/cleanup.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: Clean Up Untagged Images
2+
3+
on:
4+
schedule:
5+
- cron: 0 0 * * 0 # run at midnight every sunday
6+
workflow_dispatch:
7+
8+
jobs:
9+
cleanup_untagged_images:
10+
runs-on: ubuntu-latest
11+
permissions:
12+
packages: write
13+
steps:
14+
- name: Delete untagged images
15+
uses: actions/delete-package-versions@v5
16+
with:
17+
package-name: ${{ github.event.repository.name }}
18+
package-type: container
19+
delete-only-untagged-versions: true
20+
min-versions-to-keep: 0

0 commit comments

Comments
 (0)