Fix Docker image push condition to exclude merge queue
The push condition only excluded pull_request events, causing the builder to attempt a push on merge_group events too. Since no meta-tag rule matches merge_group, this results in a push with no tag, which fails or produces a broken image. Now only pushes on branch/tag push and workflow_dispatch.
This commit is contained in:
parent
980d5dcd1e
commit
ccbd2f971c
1 changed files with 1 additions and 1 deletions
2
.github/workflows/docker.yml
vendored
2
.github/workflows/docker.yml
vendored
|
|
@ -36,7 +36,7 @@ jobs:
|
|||
context: . # Use local checkout to support GitHub Merge Queue
|
||||
output: image
|
||||
platforms: linux/amd64,linux/arm64
|
||||
push: ${{ github.event_name != 'pull_request' }}
|
||||
push: ${{ github.event_name != 'pull_request' && github.event_name != 'merge_group' }}
|
||||
cache: ${{ github.event_name != 'workflow_dispatch' || inputs.use_cache }}
|
||||
# We don't sign the image because ghcr.io doesn't support OCI Referrers API yet, and the fallback relies on pushing new tags on each build
|
||||
# https://github.com/docker/github-builder/issues/109#issuecomment-3885082486
|
||||
|
|
|
|||
Loading…
Reference in a new issue