Skip to content

Commit

Permalink
fix: adjust ghcrCleanup workflow triggers and properly set package names
Browse files Browse the repository at this point in the history
  • Loading branch information
alismx committed Jan 3, 2024
1 parent 047cbb0 commit ee3fd81
Showing 1 changed file with 23 additions and 14 deletions.
37 changes: 23 additions & 14 deletions .github/workflows/ghcrCleanup.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
name: Delete old container images

on:
schedule:
- cron: "0 0 * * *"
push:
branches:
- alis/ghcr_clean_fix
# schedule:
# - cron: "0 0 * * *"

jobs:
clean_ghcr:
Expand All @@ -11,38 +14,44 @@ jobs:
steps:
# backend, cypress, database, frontend, frontend-lighthouse, nginx
- uses: actions/delete-package-versions@v4
with:
package-name: 'backend'
with:
package-name: 'prime-simplereport/backend'
package-type: 'container'
min-versions-to-keep: 10
delete-only-untagged-versions: 'true'
- uses: actions/delete-package-versions@v4
with:
package-name: 'cypress'
with:
package-name: 'prime-simplereport/cypress'
package-type: 'container'
min-versions-to-keep: 10
delete-only-untagged-versions: 'true'
- uses: actions/delete-package-versions@v4
with:
package-name: 'database'
with:
package-name: 'prime-simplereport/database'
package-type: 'container'
min-versions-to-keep: 10
delete-only-untagged-versions: 'true'
- uses: actions/delete-package-versions@v4
with:
package-name: 'frontend'
with:
package-name: 'prime-simplereport/db'
package-type: 'container'
min-versions-to-keep: 10
delete-only-untagged-versions: 'true'
- uses: actions/delete-package-versions@v4
with:
package-name: 'frontend-lighthouse'
with:
package-name: 'prime-simplereport/frontend'
package-type: 'container'
min-versions-to-keep: 10
delete-only-untagged-versions: 'true'
- uses: actions/delete-package-versions@v4
with:
package-name: 'nginx'
with:
package-name: 'prime-simplereport/frontend-lighthouse'
package-type: 'container'
min-versions-to-keep: 10
delete-only-untagged-versions: 'true'
- uses: actions/delete-package-versions@v4
with:
package-name: 'prime-simplereport/nginx'
package-type: 'container'
min-versions-to-keep: 10
delete-only-untagged-versions: 'true'

0 comments on commit ee3fd81

Please sign in to comment.