diff --git a/.github/workflows/aks.yaml b/.github/workflows/aks.yaml index ccc7e032..b2e48846 100644 --- a/.github/workflows/aks.yaml +++ b/.github/workflows/aks.yaml @@ -38,7 +38,10 @@ on: description: Runner template to use default: hosted-prov-e2e-ci-runner-spot-x86-64-template-n2-highmem-32-v2 type: string - + zone: + description: GCP zone to host the runner + default: us-west1-b + type: string jobs: aks-e2e: uses: ./.github/workflows/main.yaml @@ -53,3 +56,4 @@ jobs: run_support_matrix_importing_tests: ${{ inputs.run_support_matrix_importing_tests == true }} destroy_runner: ${{ inputs.destroy_runner == true }} runner_template: ${{ inputs.runner_template }} + zone: ${{inputs.zone}} diff --git a/.github/workflows/eks.yaml b/.github/workflows/eks.yaml index e3d7c31c..d8803c86 100644 --- a/.github/workflows/eks.yaml +++ b/.github/workflows/eks.yaml @@ -38,7 +38,10 @@ on: description: Runner template to use default: hosted-prov-e2e-ci-runner-spot-x86-64-template-n2-highmem-32-v2 type: string - + zone: + description: GCP zone to host the runner + default: us-west1-b + type: string jobs: eks-e2e: uses: ./.github/workflows/main.yaml @@ -53,3 +56,4 @@ jobs: run_support_matrix_importing_tests: ${{ inputs.run_support_matrix_importing_tests == true }} destroy_runner: ${{ inputs.destroy_runner == true }} runner_template: ${{ inputs.runner_template }} + zone: ${{inputs.zone}} diff --git a/.github/workflows/gke.yaml b/.github/workflows/gke.yaml index 4c645205..b70395f7 100644 --- a/.github/workflows/gke.yaml +++ b/.github/workflows/gke.yaml @@ -38,7 +38,10 @@ on: description: Runner template to use default: hosted-prov-e2e-ci-runner-spot-x86-64-template-n2-highmem-32-v2 type: string - + zone: + description: GCP zone to host the runner + default: us-west1-b + type: string jobs: gke-e2e: uses: ./.github/workflows/main.yaml @@ -53,3 +56,4 @@ jobs: run_support_matrix_importing_tests: ${{ inputs.run_support_matrix_importing_tests == true }} destroy_runner: ${{ inputs.destroy_runner == true }} runner_template: ${{ inputs.runner_template }} + zone: ${{inputs.zone}} diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index cb94cb72..372ca468 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -79,9 +79,10 @@ jobs: uses: google-github-actions/setup-gcloud@v1 - name: Create runner run: | + REGION=echo "${{ inputs.zone }}" | sed 's/-[abcdef]$//' gcloud compute instances create ${{ steps.generator.outputs.runner }} \ --zone ${{ inputs.zone }} \ - --source-instance-template ${{ inputs.runner_template }} &> /dev/null + --source-instance-template projects/${{ env.GKE_PROJECT_ID }}/regions/${REGION}/instanceTemplates/${{ inputs.runner_template }} &> /dev/null - name: Allow traffic run: | gcloud compute instances add-tags ${{ steps.generator.outputs.runner }} \