diff --git a/.github/workflows/branches.yml b/.github/workflows/branches.yml index 905471a..8159780 100644 --- a/.github/workflows/branches.yml +++ b/.github/workflows/branches.yml @@ -24,8 +24,13 @@ jobs: contents: write # Allow the job to write tags on the repo steps: - uses: actions/checkout@v4 + with: + persist-credentials: false # to avoid using GITHUB_TOKEN when pushing + + # It's required to avoid using the GITHUB_TOKEN, because we want an action to run on the tags that will be pushed. + # By default, github actions does not run on events triggered by other actions - name: Run semantic release uses: cycjimmy/semantic-release-action@v4 env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_TOKEN: ${{ secrets.SEMANTIC_RELEASE_PUSH_TOKEN }} NPM_TOKEN: "" diff --git a/.github/workflows/tags.yml b/.github/workflows/tags.yml index c9d8ee4..bb9213c 100644 --- a/.github/workflows/tags.yml +++ b/.github/workflows/tags.yml @@ -7,7 +7,7 @@ concurrency: on: push: tags: - - '[0-9]\.[0-9]\.[0-9]*' + - 'v[0-9]\.[0-9]\.[0-9]*' jobs: release: @@ -42,5 +42,5 @@ jobs: context: . file: ./docker_build/Dockerfile push: true - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} + tags: ${{ steps.docker_meta.outputs.tags }} + labels: ${{ steps.docker_meta.outputs.labels }} diff --git a/.releaserc.json b/.releaserc.json index e605b61..3269647 100644 --- a/.releaserc.json +++ b/.releaserc.json @@ -1,5 +1,4 @@ { - "tagFormat": "${version}", "branches": [ "+([0-9])?(.{+([0-9]),x}).x", "main",