Skip to content

Commit

Permalink
Add cluster for a fallback test (#122)
Browse files Browse the repository at this point in the history
Trying to address this Kokoro failure:
```
+ [21:10:41 UTC]	 Installing packages with apt, see install-apt.log
+ [21:11:21 UTC]	 Fetching GKE cluster credentials
ERROR: (gcloud.container.clusters.get-credentials) One of [--location, --zone, --region] must be supplied.
```
  • Loading branch information
eugeneo authored Aug 13, 2024
1 parent 90252c8 commit ceebea2
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion .kokoro/psm_interop_kokoro_lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -206,9 +206,11 @@ psm::dualstack::run_test() {

#######################################
# Fallback Test Suite setup.
#
# This test does not need GKE so setting variable to skip some init
#######################################
psm::fallback::setup() {
: # Placeholder for future setup commands
NO_GKE_CLUSTER=1
}

#######################################
Expand Down Expand Up @@ -911,6 +913,10 @@ gcloud_gcr_list_image_tags() {
# Writes authorization info $HOME/.kube/config
#######################################
gcloud_get_cluster_credentials() {
if [[ -n "${NO_GKE_CLUSTER}" ]]; then
psm::tools::log "Skipping cluster credentials"
return
fi
# Secondary cluster, when set.
if [[ -n "${SECONDARY_GKE_CLUSTER_NAME}" && -n "${SECONDARY_GKE_CLUSTER_ZONE}" ]]; then
gcloud container clusters get-credentials "${SECONDARY_GKE_CLUSTER_NAME}" --zone "${SECONDARY_GKE_CLUSTER_ZONE}"
Expand Down

0 comments on commit ceebea2

Please sign in to comment.