Skip to content

Commit 18815bb

Browse files
author
Eric Stroczynski
authored
workflows/deploy: push images on push to latest branch (#4846)
Signed-off-by: Eric Stroczynski <[email protected]>
1 parent 8198a26 commit 18815bb

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

.github/workflows/deploy.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,8 @@ jobs:
107107
file: ./images/${{ matrix.id }}/Dockerfile
108108
context: .
109109
platforms: linux/amd64,linux/arm64,linux/ppc64le,linux/s390x
110-
push: ${{ (github.event_name != 'pull_request' && (startsWith(github.ref, 'refs/tags/') || github.ref == format('refs/heads/{0}', github.event.repository.default_branch) )) }}
110+
# Push on tag, or master or latest branch push.
111+
push: ${{ (github.event_name != 'pull_request' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/master' || github.ref == 'refs/heads/latest')) }}
111112
tags: ${{ steps.tags.outputs.tags }}
112113

113114
# scorecard-test-kuttl image build job. Only pushes if a tag with prefix "scorecard-kuttl/v" is present.
@@ -153,5 +154,6 @@ jobs:
153154
context: .
154155
# s390x is not supported by the scorecard-test-kuttl base image.
155156
platforms: linux/amd64,linux/arm64,linux/ppc64le
156-
push: ${{ (github.event_name != 'pull_request' && (startsWith(github.ref, 'refs/tags/') || github.ref == format('refs/heads/{0}', github.event.repository.default_branch) )) }}
157+
# Push on tag, or master branch push.
158+
push: ${{ (github.event_name != 'pull_request' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/master')) }}
157159
tags: ${{ steps.tags.outputs.tags }}

0 commit comments

Comments
 (0)