Skip to content

Commit

Permalink
Update all the workflow input with GCP Zone
Browse files Browse the repository at this point in the history
Signed-off-by: Parthvi <parthvi.vala@gmail.com>
  • Loading branch information
valaparthvi committed Jan 3, 2024
1 parent 7e5913c commit 0962476
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 4 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/aks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -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}}
6 changes: 5 additions & 1 deletion .github/workflows/eks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -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}}
6 changes: 5 additions & 1 deletion .github/workflows/gke.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -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}}
3 changes: 2 additions & 1 deletion .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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 }} \
Expand Down

0 comments on commit 0962476

Please sign in to comment.