terraform_provider: correctly pass down CC technology

This commit is contained in:
Moritz Sanft 2024-04-05 15:26:18 +02:00
parent 281525f7cf
commit 26bb689c83
No known key found for this signature in database
GPG Key ID: 335D28368B1DA615
2 changed files with 12 additions and 0 deletions

View File

@ -266,11 +266,21 @@ jobs:
run: |
region=$(echo ${{ inputs.regionZone || 'europe-west3-b' }} | rev | cut -c 3- | rev)
case "${{ inputs.attestationVariant }}" in
"gcp-sev-snp")
cc_tech="SEV_SNP"
;;
*)
cc_tech="SEV"
;;
esac
cat >> _override.tf <<EOF
locals {
project_id = "constellation-e2e"
region = "${region}"
zone = "${{ inputs.regionZone || 'europe-west3-b' }}"
cc_technology = "${cc_tech}"
}
EOF
cat _override.tf

View File

@ -24,6 +24,7 @@ locals {
control_plane_count = 3
worker_count = 2
instance_type = "n2d-standard-4"
cc_technology = "SEV"
master_secret = random_bytes.master_secret.hex
master_secret_salt = random_bytes.master_secret_salt.hex
@ -79,6 +80,7 @@ module "gcp_infrastructure" {
region = local.region
project = local.project_id
internal_load_balancer = false
cc_technology = local.cc_technology
}
data "constellation_attestation" "foo" {