forked from Azure/AKS
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path02-aks-custom-vnet.json
175 lines (175 loc) · 5.28 KB
/
02-aks-custom-vnet.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
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"resourceName": {
"type": "string",
"metadata": {
"description": "The name of the Managed Cluster ARM resource. This is the AKS cluster name."
}
},
"dnsPrefix": {
"type": "string",
"metadata": {
"description": "DNS prefix to use with hosted Kubernetes API FQDN."
}
},
"servicePrincipalClientId": {
"metadata": {
"description": "Service principal client ID used by the Kubernetes cloud provider."
},
"type": "securestring"
},
"servicePrincipalClientSecret": {
"metadata": {
"description": "Service principal password used by the Kubernetes cloud provider."
},
"type": "securestring"
},
"osDiskSizeGB": {
"type": "int",
"defaultValue": 0,
"metadata": {
"description": "Disk size (in GB) to provision for each of the agent pool nodes. This value ranges from 0 to 1023. Specifying 0 will apply the default disk size for that agentVMSize."
},
"minValue": 0,
"maxValue": 1023
},
"agentCount": {
"type": "int",
"defaultValue": 3,
"metadata": {
"description": "The number of agent nodes for the cluster."
},
"minValue": 1,
"maxValue": 50
},
"agentVMSize": {
"type": "string",
"defaultValue": "Standard_D2_v2",
"metadata": {
"description": "The size of the agent node."
}
},
"osType": {
"type": "string",
"defaultValue": "Linux",
"allowedValues": [
"Linux"
],
"metadata": {
"description": "Agent operating system."
}
},
"maxPods": {
"type": "int",
"defaultValue": 30,
"metadata": {
"description": "Maximum number of pods for each agent node."
}
},
"networkPlugin": {
"type": "string",
"allowedValues": [
"kubenet",
"azure"
],
"metadata": {
"description": "IPAM plugin for AKS cluster."
}
},
"serviceCidr": {
"type": "string",
"metadata": {
"description": "IP address range to use for Kubernetes services."
}
},
"dnsServiceIP": {
"type": "string",
"metadata": {
"description": "Single IP address to use for Kubernetes DNS service. Must be within serviceCidr"
}
},
"dockerBridgeCidr": {
"type": "string",
"metadata": {
"description": "Single IP address and netmask (CIDR notation) for Docker bridge."
}
},
"vnetSubnetID": {
"type": "string",
"metadata": {
"description": "Azure Resource Manager ID for the Subnet to hold AKS agent nodes."
}
},
"kubernetesVersion": {
"type": "string",
"defaultValue": "1.9.6",
"allowedValues": [
"1.7.15",
"1.8.11",
"1.9.6"
],
"metadata": {
"description": "The version of Kubernetes."
}
}
},
"variables": {
"agentCount": "[parameters('agentCount')]",
"agentVMSize": "[parameters('agentVMSize')]",
"dnsPrefix": "[parameters('dnsPrefix')]",
"dnsServiceIP": "[parameters('dnsServiceIP')]",
"dockerBridgeCidr": "[parameters('dockerBridgeCidr')]",
"kubernetesVersion": "[parameters('kubernetesVersion')]",
"networkPlugin": "[parameters('networkPlugin')]",
"maxPods": "[parameters('maxPods')]",
"osDiskSizeGB": "[parameters('osDiskSizeGB')]",
"osType": "[parameters('osType')]",
"resourceName": "[parameters('resourceName')]",
"serviceCidr": "[parameters('serviceCidr')]",
"servicePrincipalClientId": "[parameters('servicePrincipalClientId')]",
"servicePrincipalClientSecret": "[parameters('servicePrincipalClientSecret')]",
"vnetSubnetID": "[parameters('vnetSubnetID')]"
},
"resources": [
{
"apiVersion": "2018-03-31",
"type": "Microsoft.ContainerService/managedClusters",
"location": "[resourceGroup().location]",
"name": "[variables('resourceName')]",
"properties": {
"kubernetesVersion": "[variables('kubernetesVersion')]",
"dnsPrefix": "[variables('dnsPrefix')]",
"agentPoolProfiles": [
{
"name": "agentpool",
"osDiskSizeGB": "[variables('osDiskSizeGB')]",
"count": "[variables('agentCount')]",
"vmSize": "[variables('agentVMSize')]",
"osType": "[variables('osType')]",
"vnetSubnetID": "[variables('vnetSubnetID')]",
"maxPods": "[variables('maxPods')]",
"storageProfile": "ManagedDisks"
}
],
"servicePrincipalProfile": {
"ClientId": "[variables('servicePrincipalClientId')]",
"Secret": "[variables('servicePrincipalClientSecret')]"
},
"networkProfile": {
"networkPlugin": "[variables('networkPlugin')]",
"serviceCidr": "[variables('serviceCidr')]",
"dnsServiceIP": "[variables('dnsServiceIP')]",
"dockerBridgeCidr": "[variables('dockerBridgeCidr')]"
}
}
}
],
"outputs": {
"AKS": {
"type": "object",
"value": "[reference(concat('Microsoft.ContainerService/managedClusters/', variables('resourceName')))]"
}
}
}