diff --git a/scripts/setup_workload_identity.sh b/scripts/setup_workload_identity.sh index 2a854f74f..0a18500f2 100755 --- a/scripts/setup_workload_identity.sh +++ b/scripts/setup_workload_identity.sh @@ -211,7 +211,6 @@ print_header "Step 1: Enabling required Google Cloud APIs" required_apis=( "aiplatform.googleapis.com" "cloudaicompanion.googleapis.com" - "cloudcode-pa.googleapis.com" "cloudresourcemanager.googleapis.com" "cloudtrace.googleapis.com" "iam.googleapis.com" @@ -220,8 +219,11 @@ required_apis=( "monitoring.googleapis.com" "sts.googleapis.com" ) - +# Separately enable the internal-only Cloud Code API, ignoring errors +# for public users who may not have access. +gcloud services enable "cloudcode-pa.googleapis.com" --project="${GOOGLE_CLOUD_PROJECT}" || true gcloud services enable "${required_apis[@]}" --project="${GOOGLE_CLOUD_PROJECT}" +gcloud services enable "cloudcode-pa.googleapis.com" --project="${GOOGLE_CLOUD_PROJECT}" || true print_success "APIs enabled successfully." # Step 2: Create Workload Identity Pool