mirror of
https://github.com/Microsoft/sql-server-samples.git
synced 2025-12-08 14:58:54 +00:00
109 lines
4.2 KiB
JSON
109 lines
4.2 KiB
JSON
{
|
|
"$schema": "http://schema.management.azure.com/schemas/2014-04-01-preview/deploymentTemplate.json#",
|
|
"contentVersion": "1.0.0.1",
|
|
"parameters": {
|
|
"location": {
|
|
"type": "string",
|
|
"defaultValue": "[resourceGroup().location]",
|
|
"metadata": {
|
|
"description": "Enter location. If you leave this field blank resource group location would be used."
|
|
}
|
|
},
|
|
"virtualNetworkName": {
|
|
"type": "string",
|
|
"metadata": {
|
|
"description": "Enter virtual network name. If you leave this field blank name will be created by the template."
|
|
}
|
|
},
|
|
"gatewaySubnetPrefix": {
|
|
"type": "string",
|
|
"metadata": {
|
|
"description": "The prefix for the GatewaySubnet where the VirtualNetworkGateway will be deployed. This must be at least /29."
|
|
}
|
|
},
|
|
"vpnClientAddressPoolPrefix": {
|
|
"type": "string",
|
|
"metadata": {
|
|
"description": "The IP address range from which VPN clients will receive an IP address when connected. Range specified must not overlap with on-premise network."
|
|
}
|
|
},
|
|
"publicRootCertData": {
|
|
"type": "string",
|
|
"metadata": {
|
|
"description": "Client root certificate data used to authenticate VPN clients."
|
|
}
|
|
}
|
|
},
|
|
"variables": {
|
|
"gatewayPublicIpAddressName": "[concat('GatewayIP-', uniqueString(resourceGroup().id))]",
|
|
"gatewayName": "[concat('Gateway-', uniqueString(resourceGroup().id))]",
|
|
"gatewaySubnetName": "GatewaySubnet",
|
|
"clientRootCertName": "RootCert"
|
|
},
|
|
"resources": [
|
|
{
|
|
"apiVersion": "2017-10-01",
|
|
"type": "Microsoft.Network/publicIPAddresses",
|
|
"name": "[variables('gatewayPublicIpAddressName')]",
|
|
"location": "[parameters('location')]",
|
|
"sku": {
|
|
"name": "Standard"
|
|
},
|
|
"properties": {
|
|
"publicIPAllocationMethod": "Dynamic"
|
|
}
|
|
},
|
|
{
|
|
"apiVersion": "2017-10-01",
|
|
"type": "Microsoft.Network/virtualNetworkGateways",
|
|
"name": "[variables('gatewayName')]",
|
|
"location": "[parameters('location')]",
|
|
"dependsOn": [
|
|
"[concat('Microsoft.Network/publicIPAddresses/', variables('gatewayPublicIpAddressName'))]"
|
|
],
|
|
"properties": {
|
|
"ipConfigurations": [
|
|
{
|
|
"properties": {
|
|
"privateIPAllocationMethod": "Dynamic",
|
|
"subnet": {
|
|
"id": "[resourceId('Microsoft.Network/virtualNetworks/subnets', parameters('virtualNetworkName'), variables('gatewaySubnetName'))]"
|
|
},
|
|
"publicIPAddress": {
|
|
"id": "[resourceId('Microsoft.Network/publicIPAddresses',variables('gatewayPublicIpAddressName'))]"
|
|
}
|
|
},
|
|
"name": "vnetGatewayConfig"
|
|
}
|
|
],
|
|
"sku": {
|
|
"name": "VpnGw1",
|
|
"tier": "VpnGw1"
|
|
},
|
|
"gatewayType": "Vpn",
|
|
"vpnType": "RouteBased",
|
|
"enableBgp": "false",
|
|
"vpnClientConfiguration": {
|
|
"vpnClientAddressPool": {
|
|
"addressPrefixes": [
|
|
"[parameters('vpnClientAddressPoolPrefix')]"
|
|
]
|
|
},
|
|
"vpnClientProtocols": [
|
|
"IkeV2",
|
|
"SSTP"
|
|
],
|
|
"vpnClientRootCertificates": [
|
|
{
|
|
"name": "[variables('clientRootCertName')]",
|
|
"properties": {
|
|
"PublicCertData": "[parameters('publicRootCertData')]"
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|