Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/actions/cit-run-with-retry/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,10 @@ inputs:
description: "Optional path to a JSONL file the script appends quota-failure records to. Used by the workflow to upload an artifact and aggregate an end-of-run quota summary."
required: false
default: ""
image_ref:
description: "Container image to run. Defaults to the prebuilt upstream image; pass a custom tag (e.g. `cit-custom:run-<run_id>`) when the workflow built CIT from source via the build-cit job."
required: false
default: "gcr.io/compute-image-tools/cloud-image-tests:latest"

runs:
using: composite
Expand All @@ -76,4 +80,5 @@ runs:
RETRY_DELAY_SECONDS: ${{ inputs.retry_delay_seconds }}
CREDS_PATH: ${{ inputs.creds_path }}
QUOTA_LOG_FILE: ${{ inputs.quota_log_file }}
CIT_IMAGE: ${{ inputs.image_ref }}
run: "${{ github.action_path }}/../../scripts/cit-run-with-retry.sh"
5 changes: 4 additions & 1 deletion .github/scripts/cit-run-with-retry.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@
# CREDS_PATH host path to GCP creds JSON
# QUOTA_LOG_FILE optional JSONL file to append quota-failure records to.
# Used by the workflow to aggregate a quota summary.
# CIT_IMAGE container image to run. Defaults to the upstream
# prebuilt; set to a locally-loaded tag when the
# workflow's build-cit job is active.

set -uo pipefail

Expand Down Expand Up @@ -148,7 +151,7 @@ for i in "${!attempts[@]}"; do
"${RUNTIME}" run \
-v "${CREDS_PATH}:/creds/auth.json" \
-e GOOGLE_APPLICATION_CREDENTIALS=/creds/auth.json \
gcr.io/compute-image-tools/cloud-image-tests:latest \
"${CIT_IMAGE:-gcr.io/compute-image-tools/cloud-image-tests:latest}" \
-project "${PROJECT}" \
${PARALLEL_COUNT:+-parallel_count ${PARALLEL_COUNT}} \
${PARALLEL_STAGGER:+-parallel_stagger ${PARALLEL_STAGGER}} \
Expand Down
Loading