From fd95eac710dd9692608d265f16ae1b48e5f2adf0 Mon Sep 17 00:00:00 2001 From: Daniel Lockyer Date: Fri, 11 Aug 2023 12:22:01 +0200 Subject: [PATCH] Hardcoded success criteria for running canary job refs https://github.com/TryGhost/DevOps/issues/57 - I'm not sure why but I think the `contains` are doing funky things and not allowing the build to run when we expect it to - switching to a slightly different if-statement should help with that --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5475730ecd94..4bc0d66e9698 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -780,7 +780,7 @@ jobs: ] name: Canary runs-on: ubuntu-latest - if: ${{ always() && needs.job_get_metadata.outputs.is_canary_branch == 'true' && !(contains(needs.*.result, 'cancelled') || contains(needs.*.result, 'failure') || contains(needs.*.result, 'skipped')) }} + if: always() && needs.job_get_metadata.outputs.is_canary_branch == 'true' && needs.job_required_tests.result == 'success' && needs.job_get_metadata.result == 'success' steps: - name: Output needs (for debugging) run: echo "${{ toJson(needs) }}"