-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathConnector.Arm.json
101 lines (101 loc) · 3.44 KB
/
Connector.Arm.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
101
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"location": {
"type": "string",
"metadata": {
"description": "The region where resources are deployed"
},
"defaultValue": "[resourceGroup().location]"
},
"connectorName": {
"type": "string",
"metadata": {
"description": "Name of ARM connector"
}
},
"servicePrincipalClientId": {
"type": "string",
"metadata": {
"description": "Client Id of Service principal to access to subscription"
}
},
"servicePrincipalClientSecret": {
"type": "securestring",
"metadata": {
"description": "Client secret of Service principal to access to subscription"
}
},
"servicePrincipalTenantId": {
"type": "string",
"metadata": {
"description": "Tenant Id"
}
},
"servicePrincipalResourceUri": {
"type": "string",
"metadata": {
"description": "Resource URI to request authorisation"
},
"defaultValue": "https://management.core.windows.net/"
},
"servicePrincipalGrantType": {
"type": "string",
"metadata": {
"description": "Grant type of Service Principal to access to subscription"
},
"allowedValues": [
"code",
"client_credentials"
],
"defaultValue": "client_credentials"
}
},
"variables": {
"connectors": {
"apiVersion": "[providers('Microsoft.Web', 'connections').apiVersions[0]]",
"location": "[parameters('location')]",
"arm": {
"id": "[concat(subscription().id, '/providers/Microsoft.Web/locations/', parameters('location'), '/managedApis/arm')]",
"name": "[parameters('connectorName')]",
"displayName": "[parameters('connectorName')]",
"clientId": "[parameters('servicePrincipalClientId')]",
"clientSecret": "[parameters('servicePrincipalClientSecret')]",
"tenantId": "[parameters('servicePrincipalTenantId')]",
"resourceUri": "[parameters('servicePrincipalResourceUri')]",
"grantType": "[parameters('servicePrincipalGrantType')]"
}
},
"tags": {
"author": "Justin Yoo",
"profile": "https://twitter.com/justinchronicle",
"projectUrl": "https://github.com/aliencube/ARM-Deployment-History-Cleaner",
"repositoryUrl": "https://github.com/aliencube/ARM-Deployment-History-Cleaner",
"license": "https://raw.githubusercontent.com/aliencube/ARM-Deployment-History-Cleaner/master/LICENSE"
}
},
"resources": [
{
"comments": "### CONNECTOR - ARM ###",
"apiVersion": "[variables('connectors').apiVersion]",
"type": "Microsoft.Web/connections",
"name": "[variables('connectors').arm.name]",
"location": "[variables('connectors').location]",
"properties": {
"api": {
"id": "[variables('connectors').arm.id]"
},
"displayName": "[variables('connectors').arm.displayName]",
"parameterValues": {
"token:clientId": "[variables('connectors').arm.clientId]",
"token:clientSecret": "[variables('connectors').arm.clientSecret]",
"token:TenantId": "[variables('connectors').arm.tenantId]",
"token:resourceUri": "[variables('connectors').arm.resourceUri]",
"token:grantType": "[variables('connectors').arm.grantType]"
}
}
}
],
"outputs": {}
}