-
Notifications
You must be signed in to change notification settings - Fork 5
/
key_vault_example_resources.json
100 lines (99 loc) · 3.51 KB
/
key_vault_example_resources.json
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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
{
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"keyVaultName": {
"type": "string",
"metadata": {
"description": "Specifies the name of the key vault."
}
},
"skuName": {
"type": "string",
"defaultValue": "standard",
"allowedValues": [
"standard",
"premium"
],
"metadata": {
"description": "Specifies whether the key vault is a standard vault or a premium vault."
}
},
"seedSecretValue": {
"type": "secureString",
"metadata": {
"description": "Specifies the integer value of the seed secret that you want to create."
}
},
"scrambleSecretValue": {
"type": "secureString",
"metadata": {
"description": "Specifies the integer value of the scramble secret that you want to create."
}
},
"mySecretStringSecretValue": {
"type": "secureString",
"metadata": {
"description": "Specifies the value of the connection string secret that you want to create."
}
}
},
"functions": [],
"resources": [
{
"type": "Microsoft.KeyVault/vaults",
"apiVersion": "2021-04-01-preview",
"name": "[parameters('keyVaultName')]",
"location": "[resourceGroup().location]",
"properties": {
"enabledForDeployment": false,
"enabledForDiskEncryption": false,
"enabledForTemplateDeployment": false,
"enableRbacAuthorization": true,
"accessPolicies": [],
"tenantId": "[subscription().tenantId]",
"sku": {
"name": "[parameters('skuName')]",
"family": "A"
},
"networkAcls": {
"defaultAction": "Allow",
"bypass": "AzureServices"
}
}
},
{
"type": "Microsoft.KeyVault/vaults/secrets",
"apiVersion": "2021-04-01-preview",
"name": "[format('{0}/{1}', parameters('keyVaultName'), 'seed')]",
"properties": {
"value": "[parameters('seedSecretValue')]"
},
"dependsOn": [
"[resourceId('Microsoft.KeyVault/vaults', parameters('keyVaultName'))]"
]
},
{
"type": "Microsoft.KeyVault/vaults/secrets",
"apiVersion": "2021-04-01-preview",
"name": "[format('{0}/{1}', parameters('keyVaultName'), 'scramble')]",
"properties": {
"value": "[parameters('scrambleSecretValue')]"
},
"dependsOn": [
"[resourceId('Microsoft.KeyVault/vaults', parameters('keyVaultName'))]"
]
},
{
"type": "Microsoft.KeyVault/vaults/secrets",
"apiVersion": "2021-04-01-preview",
"name": "[format('{0}/{1}', parameters('keyVaultName'), 'mysecretstring')]",
"properties": {
"value": "[parameters('mySecretStringSecretValue')]"
},
"dependsOn": [
"[resourceId('Microsoft.KeyVault/vaults', parameters('keyVaultName'))]"
]
}
]
}