diff --git a/.github/workflows/cleanup.yml b/.github/workflows/cleanup.yml new file mode 100644 index 0000000..c141a87 --- /dev/null +++ b/.github/workflows/cleanup.yml @@ -0,0 +1,27 @@ +name: Packages Cleanup + +on: + push: + branches: [ "main" ] + +jobs: + build: + + runs-on: ubuntu-latest + + permissions: + contents: read + packages: write + # This is used to complete the identity challenge + # with sigstore/fulcio when running outside of PRs. + id-token: write + + steps: + - name: Delete Untagged + uses: actions/delete-package-versions@v5 + with: + owner: ${{ github.repository_owner }} + package-type: container + package-name: glassfish + delete-only-untagged-versions: 'true' + token: ${{ secrets.GITHUB_TOKEN }}