forked from rdvansloten/letsencrypt-terraform-azure
-
Notifications
You must be signed in to change notification settings - Fork 0
/
keyvault.tf
64 lines (58 loc) · 1.48 KB
/
keyvault.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
# Create a Resource Group
resource "azurerm_resource_group" "resource_group_kv" {
name = var.keyvault_rg
location = var.region
}
# Create a Key Vault
resource "azurerm_key_vault" "vault" {
name = var.key_Vault
location = azurerm_resource_group.resource_group_kv.location
resource_group_name = azurerm_resource_group.resource_group_kv.name
sku_name = "Standard"
tenant_id = data.azurerm_client_config.current.tenant_id
soft_delete_enabled = false
enabled_for_disk_encryption = true
purge_protection_enabled = false
enabled_for_template_deployment = true
enabled_for_deployment = true
soft_delete_retention_days = 14
access_policy {
tenant_id = data.azurerm_client_config.current.tenant_id
object_id = data.azurerm_client_config.current.object_id
key_permissions = [
"get",
"list",
"update",
"create",
"import",
"delete",
"recover",
"backup",
"restore"
]
secret_permissions = [
"get",
"list",
"set",
"delete",
"recover",
"backup",
"restore"
]
certificate_permissions = [
"get",
"list",
"update",
"create",
"import",
"delete",
"recover",
"backup",
"restore"
]
}
network_acls {
default_action = "Allow"
bypass = "AzureServices"
}
}