Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Firewall Option for SKU #794 #839

Merged
merged 14 commits into from
Feb 6, 2024
Prev Previous commit
Next Next commit
update dns optoins based on SKU type
Mike Dzikowski committed Feb 5, 2024
commit daa1f799ad75e9774e707194387de50a5701c575
6 changes: 4 additions & 2 deletions src/bicep/mlz.bicep
Original file line number Diff line number Diff line change
@@ -823,7 +823,7 @@ module hubNetwork './core/hub-network.bicep' = {
virtualNetworkAddressPrefix: hubVirtualNetworkAddressPrefix
virtualNetworkName: hubVirtualNetworkName
vNetDnsServers: [
firewallClientPrivateIpAddress
(firewallSkuTier == 'Premium' || firewallSkuTier == 'Standard') ? firewallClientUsableIpAddresses : null
]
}
dependsOn: [
@@ -847,7 +847,9 @@ module spokeNetworks './core/spoke-network.bicep' = [for spoke in spokes: {
tags: calculatedTags
virtualNetworkAddressPrefix: spoke.virtualNetworkAddressPrefix
virtualNetworkName: spoke.virtualNetworkName
vNetDnsServers: [ hubNetwork.outputs.firewallPrivateIPAddress ]
vNetDnsServers: [
(firewallSkuTier == 'Premium' || firewallSkuTier == 'Standard') ? firewallClientUsableIpAddresses : null
]
}
dependsOn: [
spokeResourceGroups
7 changes: 3 additions & 4 deletions src/bicep/mlz.json
Original file line number Diff line number Diff line change
@@ -5,7 +5,7 @@
"_generator": {
"name": "bicep",
"version": "0.24.24.22086",
"templateHash": "7702273271994430092"
"templateHash": "1976072491381785844"
}
},
"parameters": {
@@ -1841,7 +1841,7 @@
},
"vNetDnsServers": {
"value": [
"[variables('firewallClientPrivateIpAddress')]"
"[if(or(equals(parameters('firewallSkuTier'), 'Premium'), equals(parameters('firewallSkuTier'), 'Standard')), variables('firewallClientUsableIpAddresses'), null())]"
]
}
},
@@ -2931,7 +2931,7 @@
},
"vNetDnsServers": {
"value": [
"[reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', parameters('hubSubscriptionId'), variables('hubResourceGroupName')), 'Microsoft.Resources/deployments', format('deploy-vnet-hub-{0}', parameters('deploymentNameSuffix'))), '2022-09-01').outputs.firewallPrivateIPAddress.value]"
"[if(or(equals(parameters('firewallSkuTier'), 'Premium'), equals(parameters('firewallSkuTier'), 'Standard')), variables('firewallClientUsableIpAddresses'), null())]"
]
}
},
@@ -3325,7 +3325,6 @@
}
},
"dependsOn": [
"[extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', parameters('hubSubscriptionId'), variables('hubResourceGroupName')), 'Microsoft.Resources/deployments', format('deploy-vnet-hub-{0}', parameters('deploymentNameSuffix')))]",
"spokeResourceGroups"
]
},