Last active
February 12, 2017 01:57
-
-
Save raykao/528f10ad393f9cc4dcbe22335ab807c5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"$schema": "https://schema.management.azure.com/schemas/2016-09-01/deploymentTemplate.json", | |
"contentVersion": "1.0.0.0", | |
"parameters": { | |
"deploymentPrefix": { | |
"type": "string" | |
}, | |
"indexCount": { | |
"type": "int" | |
}, | |
"subnetId": { | |
"type": "string" | |
}, | |
"nsgID": { | |
"type": "string" | |
}, | |
"ipAddressArray": { | |
"type": "array", | |
"defaultValue": [] | |
} | |
}, | |
"variables": { | |
"interfaceName": "[concat(parameters('deploymentPrefix'), '-nic-', padLeft(parameters('indexCount'),3,'0'))]", | |
"location": "[resourceGroup().location]" | |
}, | |
"resources": [ | |
{ | |
"type": "Microsoft.Network/networkInterfaces", | |
"name": "[variables('interfaceName')]", | |
"apiVersion": "2016-09-01", | |
"location": "[variables('location')]", | |
"properties": { | |
"ipConfigurations": [ | |
{ | |
"name": "ipconfig1", | |
"properties": { | |
"subnet": { | |
"id": "[parameters('subnetId')]" | |
}, | |
"privateIPAllocationMethod": "dynamic" | |
} | |
} | |
], | |
"networkSecurityGroup": { | |
"id": "[parameters('nsgID')]" | |
} | |
} | |
} | |
], | |
"outputs": { | |
"ipaddresses": { | |
"type" : "array", | |
"value": "[concat(parameters('ipAddressArray'), '1')]" | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment