Compare commits
4 Commits
master
...
101-attest
Author | SHA1 | Date | |
---|---|---|---|
![]() |
0fb44fea2f | ||
![]() |
d9a01d925f | ||
![]() |
60cc897714 | ||
![]() |
abdaeb1925 |
@ -21,7 +21,7 @@ resource "tls_private_key" "signing_cert" {
|
|||||||
resource "tls_self_signed_cert" "attestation" {
|
resource "tls_self_signed_cert" "attestation" {
|
||||||
count = local.create_signing_cert ? 1 : 0
|
count = local.create_signing_cert ? 1 : 0
|
||||||
|
|
||||||
private_key_pem = tls_private_key.signing_cert[0].private_key_pem
|
private_key_pem = tls_private_key.signing_cert[0].private_key_pem
|
||||||
validity_period_hours = 12
|
validity_period_hours = 12
|
||||||
allowed_uses = [
|
allowed_uses = [
|
||||||
"cert_signing",
|
"cert_signing",
|
||||||
@ -40,4 +40,13 @@ resource "azurerm_attestation_provider" "corp_attestation" {
|
|||||||
name = "${var.attestation_provider_name}${random_string.attestation_suffix.result}"
|
name = "${var.attestation_provider_name}${random_string.attestation_suffix.result}"
|
||||||
resource_group_name = azurerm_resource_group.rg.name
|
resource_group_name = azurerm_resource_group.rg.name
|
||||||
policy_signing_certificate_data = try(tls_self_signed_cert.attestation[0].cert_pem, file(var.cert_path))
|
policy_signing_certificate_data = try(tls_self_signed_cert.attestation[0].cert_pem, file(var.cert_path))
|
||||||
|
#https://github.com/hashicorp/terraform-provider-azurerm/issues/21998#issuecomment-1573312297
|
||||||
|
lifecycle {
|
||||||
|
ignore_changes = [
|
||||||
|
"open_enclave_policy_base64",
|
||||||
|
"sev_snp_policy_base64",
|
||||||
|
"sgx_enclave_policy_base64",
|
||||||
|
"tpm_policy_base64",
|
||||||
|
]
|
||||||
|
}
|
||||||
}
|
}
|
@ -4,7 +4,7 @@ terraform {
|
|||||||
required_providers {
|
required_providers {
|
||||||
azurerm = {
|
azurerm = {
|
||||||
source = "hashicorp/azurerm"
|
source = "hashicorp/azurerm"
|
||||||
version = "~>2.0"
|
version = "~>3.0"
|
||||||
}
|
}
|
||||||
random = {
|
random = {
|
||||||
source = "hashicorp/random"
|
source = "hashicorp/random"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user