From d3f3561923df8c67b448e32fcd46582462621ea8 Mon Sep 17 00:00:00 2001 From: Erik Burton Date: Thu, 26 Mar 2026 09:52:08 -0700 Subject: [PATCH 1/3] fix(ci): force build integ test images on pushes to develop --- .github/workflows/integration-tests.yml | 35 +++++++++++++++---------- 1 file changed, 21 insertions(+), 14 deletions(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 6f6c8fb8010..c6cea717340 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -221,7 +221,7 @@ jobs: dockerfile: core/chainlink.Dockerfile tag-suffix: "" # todo: optimize this conditional - should-build: >- + any-should-run: >- ${{ needs.run-core-e2e-tests-setup.outputs.should-run == 'true' || needs.run-ccip-e2e-tests-setup.outputs.should-run == 'true' || @@ -234,7 +234,7 @@ jobs: dockerfile: plugins/chainlink.Dockerfile tag-suffix: -plugins # todo: optimize this conditional - should-build: >- + any-should-run: >- ${{ needs.run-core-e2e-tests-setup.outputs.should-run == 'true' || needs.run-ccip-e2e-tests-setup.outputs.should-run == 'true' || @@ -255,24 +255,31 @@ jobs: tag: ${{ inputs.evm-ref || env.CHAINLINK_REF }}${{ matrix.image.tag-suffix }} aws-role-arn: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - - name: Explain + - name: Explain build/no-build decision + id: explain env: - SHOULD_BUILD: ${{ matrix.image.should-build }} + EVENT_NAME: ${{ github.event_name }} + REF_NAME: ${{ github.ref_name }} + ANY_SHOULD_RUN: ${{ matrix.image.any-should-run }} IMAGE_EXISTS: ${{ steps.check-image-exists.outputs.exists }} run: | - if [[ "${SHOULD_BUILD}" == 'true' && "${IMAGE_EXISTS}" == 'false' ]]; then - echo "We will build the image because the matrix's should-build is true and the image does not already exist in ECR." - echo "Should build is true when:" - echo "- For the non-plugins image: the core tests, ccip tests, or solana tests will be run." - echo "- For the plugins image: the core cre e2e tests will be run." + if [[ "${EVENT_NAME}" == "push" && "${REF_NAME}" == "develop" ]]; then + echo "We force build on pushes to develop to populate the docker layer cache." + echo "build-image=true" | tee -a "$GITHUB_OUTPUT" + elif [[ "${ANY_SHOULD_RUN}" == "true" && "${IMAGE_EXISTS}" == "false" ]]; then + echo "We will build the image because the matrix's any-should-run is true and the image does not already exist in ECR." + echo "any-should-run is true when:" + echo " - For the non-plugins image: the core tests, ccip tests, or solana tests will be run." + echo " - For the plugins image: the core cre e2e tests will be run." + + echo "build-image=true" | tee -a "$GITHUB_OUTPUT" else - echo "We will not build the image because either the matrix's should-build is false or the image already exists in ECR." - echo "should-build: ${SHOULD_BUILD}" - echo "image-exists: ${IMAGE_EXISTS}" + echo "We will not build the image because either the matrix's any-should-run is false or the image already exists in ECR." + echo "build-image=false" | tee -a "$GITHUB_OUTPUT" fi - name: Checkout the repo - if: matrix.image.should-build && steps.check-image-exists.outputs.exists != 'true' + if: steps.explain.outputs.build-image == 'true' uses: actions/checkout@v4 with: persist-credentials: false @@ -280,7 +287,7 @@ jobs: ref: ${{ env.CHAINLINK_REF }} - name: Build Chainlink Image - if: matrix.image.should-build && steps.check-image-exists.outputs.exists != 'true' + if: steps.explain.outputs.build-image == 'true' uses: smartcontractkit/.github/actions/ctf-build-image@ctf-build-image/v1 with: image-tag: ${{ inputs.evm-ref || env.CHAINLINK_REF }}${{ matrix.image.tag-suffix }} From 868b99dfb167a8cd470ab8ba374a8ffb8853ed37 Mon Sep 17 00:00:00 2001 From: Erik Burton Date: Fri, 27 Mar 2026 12:44:53 -0700 Subject: [PATCH 2/3] Update .github/workflows/integration-tests.yml Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- .github/workflows/integration-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index c6cea717340..b900b1fe960 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -266,7 +266,7 @@ jobs: if [[ "${EVENT_NAME}" == "push" && "${REF_NAME}" == "develop" ]]; then echo "We force build on pushes to develop to populate the docker layer cache." echo "build-image=true" | tee -a "$GITHUB_OUTPUT" - elif [[ "${ANY_SHOULD_RUN}" == "true" && "${IMAGE_EXISTS}" == "false" ]]; then + elif [[ "${ANY_SHOULD_RUN}" == "true" && "${IMAGE_EXISTS}" != "true" ]]; then echo "We will build the image because the matrix's any-should-run is true and the image does not already exist in ECR." echo "any-should-run is true when:" echo " - For the non-plugins image: the core tests, ccip tests, or solana tests will be run." From d3576ae9995fdec093d01e46c346a5783d0c70e6 Mon Sep 17 00:00:00 2001 From: Erik Burton Date: Wed, 1 Apr 2026 10:50:30 -0700 Subject: [PATCH 3/3] fix: merge --- .github/workflows/integration-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index aadd0d517e2..3c8093ed657 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -281,7 +281,7 @@ jobs: fi - name: Checkout the repo - if: matrix.image.should-build && steps.check-image-exists.outputs.exists != 'true' + if: steps.explain.outputs.build-image == 'true' uses: actions/checkout@v6 with: persist-credentials: false