mirror of
https://github.com/edgelesssys/constellation.git
synced 2025-01-11 23:49:30 -05:00
Choose TDX supported region for TDX tests
Signed-off-by: Daniel Weiße <dw@edgeless.systems>
This commit is contained in:
parent
ecae1c8f9a
commit
d17e7459db
2
.github/actions/e2e_test/action.yml
vendored
2
.github/actions/e2e_test/action.yml
vendored
@ -245,6 +245,8 @@ runs:
|
||||
- name: Pick a random Azure region
|
||||
id: pick-az-region
|
||||
uses: ./.github/actions/pick_azure_region
|
||||
with:
|
||||
attestationVariant: ${{ inputs.attestationVariant }}
|
||||
|
||||
- name: Create IAM configuration
|
||||
id: constellation-iam-create
|
||||
|
20
.github/actions/pick_azure_region/action.yml
vendored
20
.github/actions/pick_azure_region/action.yml
vendored
@ -1,6 +1,11 @@
|
||||
name: Pick an Azure region
|
||||
description: "Pick an Azure region"
|
||||
|
||||
inputs:
|
||||
attestationVariant:
|
||||
description: "Attestation variant to use. Not all regions support all variants."
|
||||
required: true
|
||||
|
||||
outputs:
|
||||
region:
|
||||
description: "One of the supported Azure regions"
|
||||
@ -13,12 +18,25 @@ runs:
|
||||
id: pick-region
|
||||
shell: bash
|
||||
run: |
|
||||
possibleRegions=(
|
||||
possibleRegionsSNP=(
|
||||
"westus"
|
||||
"eastus"
|
||||
"northeurope"
|
||||
"westeurope"
|
||||
"southeastasia"
|
||||
)
|
||||
possibleRegionsTDX=(
|
||||
"centralus"
|
||||
"eastus2"
|
||||
"northeurope"
|
||||
"westeurope"
|
||||
)
|
||||
|
||||
if [[ "${{ inputs.attestationVariant }}" == "azure-tdx" ]]; then
|
||||
possibleRegions=("${possibleRegionsTDX[@]}")
|
||||
else
|
||||
possibleRegions=("${possibleRegionsSNP[@]}")
|
||||
fi
|
||||
|
||||
region=${possibleRegions[$RANDOM % ${#possibleRegions[@]}]}
|
||||
echo "region=$region" | tee -a "$GITHUB_OUTPUT"
|
||||
|
Loading…
Reference in New Issue
Block a user