diff --git a/.github/workflows/publish-image.yml b/.github/workflows/publish-image.yml index 8f86f868b..d2c9f4754 100644 --- a/.github/workflows/publish-image.yml +++ b/.github/workflows/publish-image.yml @@ -34,7 +34,7 @@ jobs: - name: Get branch name id: branch-name - uses: tj-actions/branch-names@v5.1 + uses: tj-actions/branch-names@v5.4 - name: Set tag for non-default branch @@ -60,6 +60,7 @@ jobs: - name: Login to DockerHub + if: github.event_name != 'pull_request' uses: docker/login-action@v1 with: username: ${{ secrets.DOCKERHUB_USERNAME }} @@ -82,7 +83,7 @@ jobs: uses: docker/build-push-action@v2 with: context: . - push: true + push: ${{ github.event_name != 'pull_request' }} platforms: linux/amd64,linux/arm64,linux/arm/v7 tags: ${{ env.IMAGE_NAME }}:${{ env.TAG }} labels: ${{ steps.meta.outputs.labels }}