Skip to content

Commit 59b72d8

Browse files
[ci][fix] INFRAPRJ-7379: Use proper push switcher in context of 'image' output
1 parent 710f438 commit 59b72d8

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

.github/workflows/speculos-builder.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,13 @@ jobs:
3838
platform=${{ matrix.platform }}
3939
echo "PLATFORM_PAIR=${platform//\//-}" >> $GITHUB_ENV
4040
41+
if [[ "${{ github.event_name }}" == 'push' && "${{ github.ref }}" == 'refs/heads/master' ]]; then
42+
PUSH_FLAG='true'
43+
else
44+
PUSH_FLAG='false'
45+
fi
46+
echo "PUSH_FLAG=${PUSH_FLAG}" >> $GITHUB_ENV
47+
4148
- name: Clone
4249
uses: actions/checkout@v4
4350

@@ -58,10 +65,9 @@ jobs:
5865
uses: docker/build-push-action@v6
5966
id: build
6067
with:
61-
push: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
6268
file: build.Dockerfile
6369
platforms: ${{ matrix.platform }}
64-
outputs: type=image,name=ghcr.io/ledgerhq/speculos-builder,push-by-digest=true,name-canonical=true,push=true
70+
outputs: type=image,name=ghcr.io/ledgerhq/speculos-builder,push-by-digest=true,name-canonical=true,push=${{ env.PUSH_FLAG }}
6571

6672
- name: Export digest
6773
run: |

0 commit comments

Comments
 (0)