Skip to content

Commit

Permalink
feat(connectivity): Add option to set allow_non_virtual_wan_traffic i…
Browse files Browse the repository at this point in the history
…n express route gateway.
  • Loading branch information
Miltos Tsatsakis committed Mar 22, 2024
1 parent e6cb214 commit 8b46c96
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 1 deletion.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -450,6 +450,7 @@ object({
enabled = optional(bool, false)
config = optional(object({
scale_unit = optional(number, 1)
allow_non_virtual_wan_traffic = optional(bool, false)
}), {})
}), {})
vpn_gateway = optional(object({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,7 @@ locals {
enabled = true
config = {
scale_unit = 1
allow_non_virtual_wan_traffic = false
}
}
vpn_gateway = {
Expand Down
1 change: 1 addition & 0 deletions modules/connectivity/locals.tf
Original file line number Diff line number Diff line change
Expand Up @@ -1343,6 +1343,7 @@ locals {
location = location
virtual_hub_id = local.virtual_hub_resource_id[location]
scale_units = virtual_hub.config.expressroute_gateway.config.scale_unit
allow_non_virtual_wan_traffic = virtual_hub.config.expressroute_gateway.config.allow_non_virtual_wan_traffic
# Optional definition attributes
tags = try(local.custom_settings.azurerm_express_route_gateway["virtual_wan"][location].tags, local.tags)
}
Expand Down
1 change: 1 addition & 0 deletions modules/connectivity/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ variable "settings" {
enabled = optional(bool, false)
config = optional(object({
scale_unit = optional(number, 1)
allow_non_virtual_wan_traffic = optional(bool, false)
}), {})
}), {})
vpn_gateway = optional(object({
Expand Down
2 changes: 1 addition & 1 deletion resources.virtual_wan.tf
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ resource "azurerm_express_route_gateway" "virtual_wan" {
location = each.value.template.location
virtual_hub_id = each.value.template.virtual_hub_id
scale_units = each.value.template.scale_units

allow_non_virtual_wan_traffic = each.value.template.allow_non_virtual_wan_traffic
# Optional resource attributes
tags = each.value.template.tags

Expand Down
1 change: 1 addition & 0 deletions tests/modules/settings/settings.connectivity.tf
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ locals {
enabled = true
config = {
scale_unit = 1
allow_non_virtual_wan_traffic = false
}
}
vpn_gateway = {
Expand Down
1 change: 1 addition & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,7 @@ variable "configure_connectivity_resources" {
enabled = optional(bool, false)
config = optional(object({
scale_unit = optional(number, 1)
allow_non_virtual_wan_traffic = optional(bool, false)
}), {})
}), {})
vpn_gateway = optional(object({
Expand Down

0 comments on commit 8b46c96

Please sign in to comment.