2 "$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
3 "contentVersion": "1.0.0.0",
7 "defaultValue": "16.04.0-LTS",
9 "12.04.5-LTS","14.04.5-LTS","15.10","16.04.0-LTS"
12 "description": "The OS"
21 "description": "Number of VMs to provision"
26 "defaultValue": "10.0.0.2",
28 "description": "Static Private IP will be assigned to the machine"
34 "description": "entrypoint script name for k8s master"
40 "description": "entrypoint script name for k8s node"
45 "defaultValue": "Standard_D14_v2",
59 "description": "VM size"
65 "description": "Unique DNS label to assign DNS name"
71 "dnsLabelPrefix": "[concat('dns-',uniquestring(resourceGroup().id))]",
72 "customData": [ "userdata.txt" ],
73 "vmName": "[concat('k8s-host-', substring(uniquestring(resourceGroup().id),0,4))]",
74 "adminUsername": "[concat('ubuntu')]",
75 "adminPassword": "Qwertyuiop@@1",
76 "sshKeyData": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQD5zrmH1dHgXbNwP2qbNVySScnFVcEP25HBd2VJu2PiJLDhwgHj44Lj9ZvLyRFCetqd8CAKnLV5qy37rwaCtlH/t8Qb36cUGPhegxpF2++uTY0b6K7Zb6hEMBNw3J1z+GU7OoVwZJhsNAw4t8/7WWmJA4Owo99TJkEKvhCYjBCLoC5sIvG/lJsaFIG8A5MjnBlwgSZ3FsUU+aY1KYZUztodkyv7laDMOinwSvJggKrCugsqZdVo5bhmcSFbqrZa/a/wgqeok+79W0/DLh5Tlf7By46ASDKGnFlwDshPu++I3KMU3eRz0rJLOKeIUCz7k80X0WJ6BrSS7l+IrpDXV1M5 ubuntu@aria",
77 "storageAccountName": "[concat('salinuxvm', substring(uniquestring(resourceGroup().id),0,4))]",
78 "imagePublisher": "Canonical",
79 "imageOffer": "UbuntuServer",
80 "nicName": "[concat('VMNic-',variables('vmName'))]",
81 "dnsPrefix": "[concat(variables('dnsLabelPrefix'),'-',substring(uniquestring(resourceGroup().id),0,4))]",
82 "addressPrefix": "10.0.0.0/16",
83 "subnetName": "Subnet",
84 "subnetPrefix": "10.0.0.0/24",
85 "storageAccountType": "Standard_LRS",
86 "publicIPAddressType": "Dynamic",
87 "publicIPAddressName": "nicLoop100",
88 "virtualNetworkName": "[concat('VNET-',variables('vmName'))]",
89 "subnetRef": "[resourceId('Microsoft.Network/virtualNetworks/subnets/', variables('virtualNetworkName'), variables('subnetName'))]",
90 "networkSecurityGroupName": "[concat(variables('vmName'), '_obrien_local_nsg')]",
91 "sshKeyPathRoot": "[concat('/root/','/.ssh/authorized_keys')]",
92 "sshKeyPath": "[concat('/home/',variables('adminUsername'),'/.ssh/authorized_keys')]",
93 "availabilitySetName": "[concat('availabilitySet-',substring(uniquestring(resourceGroup().id),0,4))]"
97 "type": "Microsoft.Compute/availabilitySets",
98 "name": "[variables('availabilitySetName')]",
99 "apiVersion": "2016-04-30-preview",
100 "location": "[resourceGroup().location]",
103 "platformFaultDomainCount": 3,
104 "platformUpdateDomainCount": 3
108 "type": "Microsoft.Storage/storageAccounts",
109 "name": "[variables('storageAccountName')]",
110 "apiVersion": "2017-06-01",
111 "location": "[resourceGroup().location]",
113 "name": "[variables('storageAccountType')]"
119 "apiVersion": "2017-03-01",
120 "type": "Microsoft.Network/networkSecurityGroups",
121 "name": "[variables('networkSecurityGroupName')]",
122 "location": "[resourceGroup().location]",
129 "name": "SSHAllowAny",
131 "description": "SSHAllowAny",
133 "sourcePortRange": "*",
134 "destinationPortRange": "22",
135 "sourceAddressPrefix": "*",
136 "destinationAddressPrefix": "*",
139 "direction": "Inbound"
143 "name": "DockerAllowAny",
145 "description": "DockerAllowAny",
147 "sourcePortRange": "*",
148 "destinationPortRange": "2376",
149 "sourceAddressPrefix": "*",
150 "destinationAddressPrefix": "*",
153 "direction": "Inbound"
157 "name": "port500-UdpAllowAny",
159 "description": "port500-udpAllowAny",
161 "sourcePortRange": "*",
162 "destinationPortRange": "500",
163 "sourceAddressPrefix": "*",
164 "destinationAddressPrefix": "*",
167 "direction": "Inbound"
171 "name": "port4500-UdpAllowAny",
173 "description": "port4500-udpAllowAny",
175 "sourcePortRange": "*",
176 "destinationPortRange": "4500",
177 "sourceAddressPrefix": "*",
178 "destinationAddressPrefix": "*",
181 "direction": "Inbound"
186 "name": "port_10249-10255_172",
188 "description": "port_10249-10255_172",
190 "sourcePortRange": "*",
191 "destinationPortRange": "10249-10255",
192 "sourceAddressPrefix": "*",
193 "destinationAddressPrefix": "*",
196 "direction": "Inbound"
202 "description": "All in",
204 "sourcePortRange": "*",
205 "destinationPortRange": "*",
206 "sourceAddressPrefix": "Internet",
207 "destinationAddressPrefix": "*",
210 "direction": "Inbound"
214 "name": "block-8080",
216 "description": "block-8080",
218 "sourcePortRange": "8080",
219 "destinationPortRange": "*",
220 "sourceAddressPrefix": "Internet",
221 "destinationAddressPrefix": "*",
224 "direction": "Outbound"
230 "description": "All out",
232 "sourcePortRange": "*",
233 "destinationPortRange": "*",
234 "sourceAddressPrefix": "Internet",
235 "destinationAddressPrefix": "*",
238 "direction": "Outbound"
245 "apiVersion": "2017-04-01",
246 "type": "Microsoft.Network/virtualNetworks",
247 "name": "[variables('virtualNetworkName')]",
248 "location": "[resourceGroup().location]",
250 "[concat('Microsoft.Network/networkSecurityGroups/', variables('networkSecurityGroupName'))]"
255 "[variables('addressPrefix')]"
260 "name": "[variables('subnetName')]",
262 "addressPrefix": "[variables('subnetPrefix')]",
263 "networkSecurityGroup": {
264 "id": "[resourceId('Microsoft.Network/networkSecurityGroups', variables('networkSecurityGroupName'))]"
272 "apiVersion": "2017-08-01",
273 "type": "Microsoft.Network/networkInterfaces",
274 "name": "[concat(variables('nicName'), copyindex())]",
275 "location": "[resourceGroup().location]",
278 "count": "[parameters('numberOfVms')]"
281 "[resourceId('Microsoft.Network/publicIPAddresses/', concat('nicLoop',copyIndex(100)))]",
282 "[resourceId('Microsoft.Network/virtualNetworks/', variables('virtualNetworkName'))]"
285 "ipConfigurations": [
289 "privateIPAllocationMethod": "Static",
290 "privateIPAddress": "[concat(parameters('privateIPAddress'),copyindex())]",
292 "id": "[resourceId('Microsoft.Network/publicIPAddresses', concat('nicLoop',copyIndex(100)))]"
295 "id": "[variables('subnetRef')]"
303 "apiVersion": "2017-04-01",
304 "type": "Microsoft.Network/publicIPAddresses",
305 "name": "[concat('nicLoop',copyIndex(100))]",
306 "location": "[resourceGroup().location]",
309 "count": "[parameters('numberOfVms')]"
312 "publicIPAllocationMethod": "Dynamic",
314 "domainNameLabel": "[concat(variables('vmName'),parameters('dnslabel'), copyIndex(1000))]"
319 "apiVersion": "2017-03-30",
320 "type": "Microsoft.Compute/virtualMachines",
321 "name": "[concat(variables('vmName'), copyindex())]",
323 "name": "virtualMachineLoop",
324 "count": "[parameters('numberOfVms')]"
326 "location": "[resourceGroup().location]",
329 "[concat('Microsoft.Compute/availabilitySets/',variables('availabilitySetName'))]"
333 "vmSize": "[parameters('vmSize')]"
336 "id": "[resourceId('Microsoft.Compute/availabilitySets',variables('availabilitySetName'))]"
339 "computerName": "[concat(variables('vmName'), copyindex())]",
340 "adminUsername": "[variables('adminUsername')]",
341 "adminPassword": "[variables('adminPassword')]",
342 "linuxConfiguration": {
343 "disablePasswordAuthentication": false,
347 "path": "[variables('sshKeyPath')]",
348 "keyData": "[variables('sshKeyData')]"
356 "publisher": "[variables('imagePublisher')]",
357 "offer": "[variables('imageOffer')]",
358 "sku": "[parameters('centosOSVersion')]",
363 "createOption": "FromImage"
367 "networkInterfaces": [
369 "id": "[resourceId('Microsoft.Network/networkInterfaces',concat(variables('nicName'),copyindex()))]"
373 "diagnosticsProfile": {
376 "storageUri": "[concat(reference(concat('Microsoft.Storage/storageAccounts/', variables('storageAccountName')), '2016-01-01').primaryEndpoints.blob)]"
382 "apiVersion": "2015-06-15",
383 "type": "Microsoft.Compute/virtualMachines/extensions",
384 "name": "[concat(variables('vmName'), '0','/onap')]",
385 "location": "[resourceGroup().location]",
386 "dependsOn": ["virtualMachineLoop"],
388 "publisher": "Microsoft.Azure.Extensions",
389 "type": "CustomScript",
390 "typeHandlerVersion": "2.0",
391 "autoUpgradeMinorVersion": true,
393 "fileUris": [ "https://gerrit.onap.org/r/gitweb?p=integration.git;a=blob_plain;f=Azure_ARM_Template/scripts/azure-rancher-server.sh;hb=refs/heads/master" ],
394 "commandToExecute": "[concat('./' , parameters('masterScriptName'),' ',reference(variables('publicIPAddressName')).dnsSettings.fqdn,' ',parameters('privateIPAddress'),' ',parameters('numberOfVms'))]"
399 "apiVersion": "2015-06-15",
400 "type": "Microsoft.Compute/virtualMachines/extensions",
401 "name": "[concat(variables('vmName'), copyindex(1),'/onap')]",
403 "name": "virtualMachineExtnLoop",
404 "count": "[sub(parameters('numberOfVms'),1)]"
406 "location": "[resourceGroup().location]",
411 "publisher": "Microsoft.Azure.Extensions",
412 "type": "CustomScript",
413 "typeHandlerVersion": "2.0",
414 "autoUpgradeMinorVersion": true,
416 "fileUris": [ "https://gerrit.onap.org/r/gitweb?p=integration.git;a=blob_plain;f=Azure_ARM_Template/scripts/azure-k8s-node.sh;hb=refs/heads/master" ],
417 "commandToExecute": "[concat('./' , parameters('nodeScriptName'),' ',concat(parameters('privateIPAddress'),'0'))]"