Skip to content

Commit

Permalink
Fix test failure
Browse files Browse the repository at this point in the history
  • Loading branch information
jaredfholgate committed Nov 28, 2024
1 parent 7d7fc8f commit 736b85d
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 17 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/end-to-end-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ jobs:
uses: hashicorp/setup-terraform@v3
with:
terraform_version: latest
terraform_wrapper: true
terraform_wrapper: false

- name: Setup Module Inputs
run: |
Expand All @@ -77,16 +77,16 @@ jobs:
run: |
terraform -chdir="${{ matrix.rootModuleFolderPath }}" init
terraform -chdir="${{ matrix.rootModuleFolderPath }}" plan -var-file="${{ matrix.configFilePath }}" -out=tfplan
terraform -chdir="${{ matrix.rootModuleFolderPath }}" show -json tfplan > tfplan.json
shell: pwsh
env:
ARM_TENANT_ID: ${{ vars.ARM_TENANT_ID }}
ARM_SUBSCRIPTION_ID: ${{ vars.ARM_SUBSCRIPTION_ID }}
ARM_CLIENT_ID: ${{ vars.ARM_CLIENT_ID }}
ARM_USE_OIDC: true

- name: Plan Summary
if: always()
run: |
terraform -chdir="${{ matrix.rootModuleFolderPath }}" show -json tfplan > tfplan.json
$planJson = Get-Content -Raw tfplan.json
$planObject = ConvertFrom-Json $planJson -Depth 100
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ hub_and_spoke_vnet_virtual_networks = {
subnets = {
nva = {
name = "subnet-nva-$${starter_location_01}"
address_prefix = "$${primary_nva_subnet_address_prefix}"
address_prefixes = ["$${primary_nva_subnet_address_prefix}"]
}
}
}
Expand Down Expand Up @@ -323,7 +323,7 @@ hub_and_spoke_vnet_virtual_networks = {
subnets = {
nva = {
name = "subnet-nva-$${starter_location_02}"
address_prefix = "$${secondary_nva_subnet_address_prefix}"
address_prefixes = ["$${secondary_nva_subnet_address_prefix}"]
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ virtual_wan_virtual_hubs = {
subnets = {
nva = {
name = "subnet-nva-$${starter_location_01}"
address_prefix = "$${primary_nva_subnet_address_prefix}"
address_prefixes = ["$${primary_nva_subnet_address_prefix}"]
}
}
}
Expand All @@ -297,15 +297,6 @@ virtual_wan_virtual_hubs = {
location = "$${starter_location_02}"
address_prefix = "$${secondary_hub_address_space}"
}
firewall = {
name = "fw-hub-$${starter_location_02}"
sku_name = "AZFW_Hub"
sku_tier = "Standard"
zones = "$${starter_location_02_availability_zones}"
firewall_policy = {
name = "fwp-hub-$${starter_location_02}"
}
}
private_dns_zones = {
resource_group_name = "$${dns_resource_group_name}"
is_primary = false
Expand All @@ -332,7 +323,7 @@ virtual_wan_virtual_hubs = {
subnets = {
nva = {
name = "subnet-nva-$${starter_location_02}"
address_prefix = "$${secondary_nva_subnet_address_prefix}"
address_prefixes = ["$${secondary_nva_subnet_address_prefix}"]
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ locals {
hub_virtual_networks = {
for key, value in var.hub_virtual_networks : key => merge(value.hub_virtual_network, {
ddos_protection_plan_id = local.ddos_protection_plan_enabled ? module.ddos_protection_plan[0].resource.id : try(value.hub_virtual_network.ddos_protection_plan_id, null)
firewall = merge(value.hub_virtual_network.firewall, {
firewall = try(value.hub_virtual_network.firewall, null) == null ? null : merge(value.hub_virtual_network.firewall, {
firewall_policy = merge(value.hub_virtual_network.firewall.firewall_policy, {
dns = merge({
proxy_enabled = can(value.private_dns_zones.resource_group_name) && can(value.hub_virtual_network.firewall) ? true : try(value.hub_virtual_network.firewall.firewall_policy.dns.proxy_enabled, false)
Expand Down

0 comments on commit 736b85d

Please sign in to comment.