File tree Expand file tree Collapse file tree 2 files changed +11
-8
lines changed Expand file tree Collapse file tree 2 files changed +11
-8
lines changed Original file line number Diff line number Diff line change @@ -2,19 +2,22 @@ name: Delete Old Docker Image
22
33on :
44 workflow_dispatch :
5-
5+ push :
6+ branches :
7+ - main
68jobs :
79
810 cleanup-pg :
911 runs-on : ubuntu-latest
12+
1013 steps :
1114
1215 - name : Cleanup Docker images from GHCR
1316 uses : dataaxiom/ghcr-cleanup-action@v1
1417 with :
15- token : ${{ secrets.GITHUB_TOKEN }}
16- owner : ${{ github.repository_owner }}
17- repository : multi-repo/Postgres
18+ token : ${{ secrets.PERSONAL_ACCESS_TOKEN }}
19+ owner : multi-repo
20+ repository : postgres
1821 keep-n-tagged : 1
19- package : multi-repo/Postgres /pg
22+ package : postgres /pg
2023 dry-run : false
Original file line number Diff line number Diff line change 11name : Build Docker Images
22
33on :
4+ release :
5+ types : [published]
46 push :
57 branches :
68 - main
7- release :
8- types : [created, published, released]
99
1010
1111jobs :
6262 curl -X POST \
6363 -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
6464 -H "Accept: application/vnd.github.v3+json" \
65- https://api.github.com/repos/${{ github.repository }}/actions/workflows/delete-old-image.yml/dispatches \
65+ https://api.github.com/repos/${{ github.repository }}/actions/workflows/delete-old-image.yml \
6666 -d '{"ref": "main"}'
6767
6868
You can’t perform that action at this time.
0 commit comments