Skip to content

Commit

Permalink
gh/workflow: change multicluster provisioning to none blocking mode
Browse files Browse the repository at this point in the history
Multicluster test set up two clusters in blocking mode in sequentially.
Every cluster provisioning takes 4 to 5 min.
This commit changes provisioning to none blocking mode and adds
a step to wait for provisioning to finish.

This change would cut the run time by 4 to 5 min.

Signed-off-by: Birol Bilgin <[email protected]>
  • Loading branch information
brlbil authored and tklauser committed May 31, 2023
1 parent 6134783 commit 6ae517c
Showing 1 changed file with 19 additions and 11 deletions.
30 changes: 19 additions & 11 deletions .github/workflows/multicluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -119,16 +119,8 @@ jobs:
--disk-type pd-standard \
--disk-size 10GB \
--node-taints node.cilium.io/agent-not-ready=true:NoExecute \
--preemptible
- name: Get cluster 2 credentials
run: |
gcloud container clusters get-credentials ${{ env.clusterName2 }} --zone ${{ env.zone }}
- name: Create gcloud-free kubeconfig for cluster 2
run: |
.github/get-kubeconfig.sh
mv kubeconfig kubeconfig-cluster2
--preemptible \
--async
- name: Create GKE cluster 1
run: |
Expand All @@ -145,7 +137,23 @@ jobs:
--disk-type pd-standard \
--disk-size 10GB \
--node-taints node.cilium.io/agent-not-ready=true:NoExecute \
--preemptible
--preemptible \
--async
- name: Wait for clusters to be provisioned
run: |
while [ "$(gcloud container operations list --filter="status=RUNNING AND targetLink~${{ env.clusterNameBase }}" --format="value(name)")" ];do
echo "cluster has an ongoing operation, waiting for all operations to finish"; sleep 10
done
- name: Get cluster 2 credentials
run: |
gcloud container clusters get-credentials ${{ env.clusterName2 }} --zone ${{ env.zone }}
- name: Create gcloud-free kubeconfig for cluster 2
run: |
.github/get-kubeconfig.sh
mv kubeconfig kubeconfig-cluster2
- name: Get cluster 1 credentials
run: |
Expand Down

0 comments on commit 6ae517c

Please sign in to comment.