Open vamsee-konda opened 3 years ago
Hi,
Isn't it better to use dynamic than count for this module?
resource "azurerm_route_table" "rtable" { name = "${var.route_table_name}" location = "${var.location}" resource_group_name = "${var.resource_group_name}" disable_bgp_route_propagation = "${var.disable_bgp_route_propagation}" dynamic "route" { for_each = var.routes content { name = route.value["route_name"] address_prefix = route.value["address_prefix"] next_hop_type = route.value["next_hop_type"] next_hop_in_ip_address = route.value["next_hop_type"] == "VirtualAppliance" ? route.value["next_hop_in_ip_address"] : null } } } resource "azurerm_subnet_route_table_association" "example" { subnet_id = var.subnet_id route_table_id = azurerm_route_table.rtable.id count = var.create_submodule_routetable_association }
There is some additional code in here for association with a subnet.
Hi,
Isn't it better to use dynamic than count for this module?
There is some additional code in here for association with a subnet.