From 511ee7cf5cfa981f9dc1aa79288e43ce8ea66378 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=A9vin=20Dunglas?= Date: Sat, 23 Dec 2023 13:52:39 +0100 Subject: [PATCH] ci: fix scheduled builds --- .github/workflows/docker.yaml | 4 ++-- .github/workflows/static.yaml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/docker.yaml b/.github/workflows/docker.yaml index b8963c1718..8d81b9d2a6 100644 --- a/.github/workflows/docker.yaml +++ b/.github/workflows/docker.yaml @@ -22,7 +22,7 @@ jobs: runs-on: ubuntu-latest outputs: # Push if it's a scheduled job, a tag, or if we're committing to the main branch - push: ${{ toJson(github.event_name == 'schedule' || (github.event_name == 'workflow_dispatch' && inputs.version) || startsWith(github.ref, 'refs/tags/') || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request')) }} + push: ${{ (github.event_name == 'schedule' || (github.event_name == 'workflow_dispatch' && inputs.version) || startsWith(github.ref, 'refs/tags/') || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request')) && true || false }} variants: ${{ steps.matrix.outputs.variants }} platforms: ${{ steps.matrix.outputs.platforms }} metadata: ${{ steps.matrix.outputs.metadata }} @@ -64,7 +64,7 @@ jobs: } >> "${GITHUB_OUTPUT}" - uses: actions/checkout@v4 - if: ${{ !fromJson(steps.check.outputs.skip) }} + if: ${{ !steps.check.outputs.skip }} with: ref: ${{ steps.check.outputs.ref }} - diff --git a/.github/workflows/static.yaml b/.github/workflows/static.yaml index 7c2dc025f2..81f772ebd9 100644 --- a/.github/workflows/static.yaml +++ b/.github/workflows/static.yaml @@ -57,8 +57,8 @@ jobs: uses: docker/bake-action@v4 with: pull: true - load: ${{toJson(!needs.prepare.outputs.ref && !startsWith(github.ref, 'refs/tags/') && (github.ref != 'refs/heads/main' || github.event_name == 'pull_request'))}} - push: ${{toJson(needs.prepare.outputs.ref || startsWith(github.ref, 'refs/tags/') || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request'))}} + load: ${{ (!needs.prepare.outputs.ref && !startsWith(github.ref, 'refs/tags/') && (github.ref != 'refs/heads/main' || github.event_name == 'pull_request')) && true || false }} + push: ${{ (needs.prepare.outputs.ref || startsWith(github.ref, 'refs/tags/') || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request')) && true || false }} targets: static-builder set: | *.cache-from=type=gha,scope=${{needs.prepare.outputs.ref || github.ref}}-static-builder