diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e749661..81c024b 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -2,12 +2,18 @@ name: Release on: workflow_dispatch: - release: - types: [published] + push: + tags: + - 'noble-*' + - 'jammy-*' + +permissions: + contents: write + packages: write + jobs: build: runs-on: ubuntu-latest - if: "!contains(github.event.head_commit.message, '[ci-skip]')" steps: - name: Checkout uses: actions/checkout@v4 @@ -76,7 +82,7 @@ jobs: password: ${{ secrets.DOCKER_PASSWORD }} - name: Build and Push - uses: docker/build-push-action@v5 + uses: docker/build-push-action@v6 with: builder: ${{ steps.buildx.outputs.name }} context: image @@ -84,3 +90,13 @@ jobs: push: ${{ steps.prep.outputs.push }} tags: ${{ steps.prep.outputs.tags }} build-args: BASE_IMAGE=${{ steps.prep.outputs.base_image }} + + - name: Create GitHub Release + if: startsWith(github.ref, 'refs/tags/') + run: | + gh release create "${{ github.ref_name }}" \ + --repo "${{ github.repository }}" \ + --title "${{ github.ref_name }}" \ + --generate-notes + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/scheduled-build.yml b/.github/workflows/scheduled-build.yml index a4beae7..1063379 100644 --- a/.github/workflows/scheduled-build.yml +++ b/.github/workflows/scheduled-build.yml @@ -81,7 +81,7 @@ jobs: password: ${{ secrets.DOCKER_PASSWORD }} - name: Build and Push - uses: docker/build-push-action@v5 + uses: docker/build-push-action@v6 with: context: image platforms: ${{ steps.prep.outputs.platforms }} diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index d6068b9..6f2058b 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -9,7 +9,6 @@ jobs: steps: - uses: actions/stale@v9 with: - repo-token: ${{ secrets.GITHUB_TOKEN }} stale-issue-message: 'This Issue has been automatically marked as "stale" because it has not had recent activity (for 15 days). It will be closed if no further activity occurs. Thanks for the feedback.' stale-pr-message: 'This Pull Request has been automatically marked as "stale" because it has not had recent activity (for 15 days). It will be closed if no further activity occurs. Thank you for your contribution.' close-issue-message: 'Due to the lack of activity in the last 5 days since it was marked as "stale", we proceed to close this Issue. Do not hesitate to reopen it later if necessary.'