Skip to content

Commit ff12688

Browse files
authored
build: Only push merged image to registry
Currently, the workflow creates broken container images because it pushes incomplete images to the registry by tag. This change will only push the digests to the registry in the build jobs and only allow the merge job to push the tags.
1 parent 55336e0 commit ff12688

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

.github/workflows/docker.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,8 @@ jobs:
7272
uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83
7373
with:
7474
platforms: ${{ matrix.platform }}
75-
push: ${{ github.event_name != 'pull_request' }}
76-
tags: ${{ steps.meta.outputs.tags }}
7775
labels: ${{ steps.meta.outputs.labels }}
76+
outputs: type=image,name=${{ steps.login-ecr.outputs.registry }}/nexhealth/backend,push-by-digest=${{ github.event_name != 'pull_request' }},name-canonical=true,push=${{ github.event_name != 'pull_request' }}
7877
cache-from: type=gha
7978
cache-to: type=gha,mode=max
8079

0 commit comments

Comments
 (0)