77 required : true
88 description : " The ref we want to compile"
99 type : string
10+ push :
11+ branches :
12+ - " ci-gha-*"
1013
1114permissions :
1215 contents : read
@@ -28,56 +31,25 @@ jobs:
2831 steps :
2932 - uses : actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5
3033 with :
31- ref : ${{ inputs.checkout-ref }}
32- - id : auth
33- uses : google-github-actions/auth@v2
34- with :
35- create_credentials_file : true
36- credentials_json : ${{ secrets.BUILD_CACHE_KEY }}
37- - name : Set up Cloud SDK
38- uses : google-github-actions/setup-gcloud@v2
39- - name : vcpkg-version
40- id : vcpkg-version
41- run : |
42- echo "version=$(cat ci/etc/vcpkg-version.txt)" >> "${GITHUB_OUTPUT}"
43- shell : bash
44- - name : install ninja and CMake
45- run : |
46- rm /usr/local/bin/cmake
47- sudo apt install ninja-build cmake
48- - name : download-sccache
49- working-directory : " ${{runner.temp}}"
50- run : |
51- curl -fsSL https://github.com/mozilla/sccache/releases/download/v0.7.1/sccache-v0.7.1-x86_64-unknown-linux-musl.tar.gz | \
52- tar -zxf - --strip-components=1 && \
53- sudo mv sccache /usr/bin/sccache && \
54- sudo chmod +x /usr/bin/sccache
55- - name : download-vcpkg
56- working-directory : " ${{runner.temp}}"
57- run : |
58- mkdir -p vcpkg
59- curl -fsSL "https://github.com/microsoft/vcpkg/archive/${STEPS_VCPKG_VERSION_OUTPUTS_VERSION}.tar.gz" |
60- tar -C vcpkg --strip-components=1 -zxf -
61- vcpkg/bootstrap-vcpkg.sh -disableMetrics
62- env :
63- STEPS_VCPKG_VERSION_OUTPUTS_VERSION : ${{ steps.vcpkg-version.outputs.version }}
64- # First compile the code using the identity with access to the build cache
65- - run : |
66- env VCPKG_ROOT="${{ runner.temp }}/vcpkg" ci/gha/builds/external-account.sh
67- # Then switch to the BYOID identity and run the integration test
34+ ref : ${{ inputs.checkout-ref || github.sha }}
35+ # Use BYOID identity and run the integration test
6836 - id : byoid-auth
6937 if : ' !github.event.pull_request.head.repo.fork'
7038 name : ' Authenticate to GCP'
71- uses : ' google-github-actions/auth@v2 '
39+ uses : ' google-github-actions/auth@v3 '
7240 with :
7341 create_credentials_file : true
7442 workload_identity_provider : ' projects/49427430084/locations/global/workloadIdentityPools/github-wif-pool/providers/github-wif-provider'
7543 service_account : ' github-actions@cloud-cpp-identity-federation.iam.gserviceaccount.com'
76- - run : |
77- ctest --test-dir cmake-out --output-on-failure -R common_internal_external_account_integration_test
78- env :
79- SCCACHE_GCS_BUCKET : cloud-cpp-gha-cache
80- SCCACHE_GCS_KEY_PREFIX : sccache/ubuntu-22.04/${{ github.job }}
81- SCCACHE_GCS_RW_MODE : READ_WRITE
82- SCCACHE_IGNORE_SERVER_IO_ERROR : 1
83- VCPKG_BINARY_SOURCES : x-gcs,gs://cloud-cpp-gha-cache/vcpkg-cache/ubuntu-22.04/${{ github.job }},readwrite
44+ - name : Run integration tests
45+ if : ' !github.event.pull_request.head.repo.fork'
46+ run : |
47+ bazelisk test \
48+ --test_output=all \
49+ --verbose_failures=true \
50+ --keep_going \
51+ --experimental_convenience_symlinks=ignore \
52+ --remote_upload_local_results=false \
53+ --test_env=GOOGLE_APPLICATION_CREDENTIALS="${GOOGLE_APPLICATION_CREDENTIALS}" \
54+ --test_env=GOOGLE_CLOUD_CPP_TEST_WIF_BUCKET="cloud-cpp-wif-test-bucket" \
55+ //google/cloud:internal_external_account_integration_test
0 commit comments