diff --git a/.github/actions/build-test-image/action.yml b/.github/actions/build-test-image/action.yml index 38bcbf8dad3..58a984bbb85 100644 --- a/.github/actions/build-test-image/action.yml +++ b/.github/actions/build-test-image/action.yml @@ -26,6 +26,17 @@ inputs: description: The AWS region the ECR repository is located in, should only be needed for public ECR repositories, used in configuring docker/login-action required: true +outputs: + test_image: + description: The full name of the test image that was built + value: ${{ steps.image_outputs.outputs.test_image }} + test_image_tag: + description: The tag of the test image that was built + value: ${{ steps.image_outputs.outputs.test_image_tag }} + test_image_repository: + description: The repository of the test image that was built + value: ${{ steps.image_outputs.outputs.test_image_repo }} + runs: using: composite steps: @@ -129,4 +140,11 @@ runs: run: | echo "### ${INPUTS_REPOSITORY} image tag for this test run :ship:" >>$GITHUB_STEP_SUMMARY echo "\`${INPUTS_TAG}\`" >>$GITHUB_STEP_SUMMARY + - name: Set outputs + id: image_outputs + shell: sh + run: | + echo "test_image_repo=${{ inputs.repository }}" >> $GITHUB_OUTPUT + echo "test_image_tag=${{ inputs.tag || steps.test_runner_hash.outputs.hash_value }}" >> $GITHUB_OUTPUT + echo "test_image=${{ inputs.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ inputs.QA_AWS_REGION }}.amazonaws.com/${{ inputs.repository }}:${{ inputs.tag || steps.test_runner_hash.outputs.hash_value }}" >> $GITHUB_OUTPUT # End Test Runner Logic diff --git a/.github/workflows/on-demand-ocr-soak-test.yml b/.github/workflows/on-demand-ocr-soak-test.yml index 4651e82523c..c3e895b428d 100644 --- a/.github/workflows/on-demand-ocr-soak-test.yml +++ b/.github/workflows/on-demand-ocr-soak-test.yml @@ -80,6 +80,7 @@ jobs: echo "### Test config override path" >> $GITHUB_STEP_SUMMARY echo "[${{ inputs.test_config_override_path }}]($GITHUB_SERVER_URL/$GITHUB_REPOSITORY/blob/${{ github.sha }}/${{ inputs.test_config_override_path }})" >> $GITHUB_STEP_SUMMARY - name: Build Image + id: build_test_image uses: ./.github/actions/build-test-image with: QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} @@ -91,7 +92,7 @@ jobs: DETACH_RUNNER: true TEST_SUITE: soak TEST_ARGS: -test.timeout 900h -test.memprofile memprofile.out -test.cpuprofile profile.out - ENV_JOB_IMAGE: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ secrets.QA_AWS_REGION }}.amazonaws.com/chainlink-tests:${{ github.sha }} + ENV_JOB_IMAGE: ${{ steps.build_test_image.outputs.test_image }} # We can comment these out when we have a stable soak test and aren't worried about resource consumption TEST_UPLOAD_CPU_PROFILE: true TEST_UPLOAD_MEM_PROFILE: true diff --git a/.github/workflows/run-e2e-tests-reusable-workflow.yml b/.github/workflows/run-e2e-tests-reusable-workflow.yml index 819e0529db2..e624e5e6b01 100644 --- a/.github/workflows/run-e2e-tests-reusable-workflow.yml +++ b/.github/workflows/run-e2e-tests-reusable-workflow.yml @@ -598,6 +598,7 @@ jobs: - name: Checkout repository uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # v4.1.2 - name: Build Test Runner Image + id: build-test-runner-image uses: ./.github/actions/build-test-image if: ${{ inputs.with_existing_remote_runner_version == '' }} with: @@ -608,7 +609,9 @@ jobs: id: set-remote-runner-version run: | if [[ -z "${{ inputs.with_existing_remote_runner_version }}" ]]; then - echo "remote-runner-version=${{ github.sha }}" >> $GITHUB_OUTPUT + echo "remote-runner-image=${{ steps.build-test-runner-image.outputs.test_image }}" >> $GITHUB_OUTPUT + echo "remote-runner-repository=${{ steps.build-test-runner-image.outputs.test_image_repository }}" >> $GITHUB_OUTPUT + echo "remote-runner-version=${{ steps.build-test-runner-image.outputs.test_image_tag }}" >> $GITHUB_OUTPUT else echo "remote-runner-version=${{ inputs.with_existing_remote_runner_version }}" >> $GITHUB_OUTPUT fi