From 16b0916774396f2e533269f65342ab49c17bf4c8 Mon Sep 17 00:00:00 2001 From: badra001 Date: Wed, 7 Dec 2022 14:16:06 -0500 Subject: [PATCH] - vpc-transit-gateway-association/self - add route propagation for vpc into VPN route table - if vpn_route_prefix_list_name == null, do not create vpn route or route propagation --- CHANGELOG.md | 6 ++++++ common/version.tf | 2 +- vpc-transit-gateway-association/self/associate.tf | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e95600d..32d113a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -222,3 +222,9 @@ * 2.4.4 -- 2022-11-04 - subnets - add offset, enabled, availability_zone + +* 2.4.5 -- 2022-12-07 + - vpc-transit-gateway-association/self + - add route propagation for vpc into VPN route table + - if vpn_route_prefix_list_name == null, do not create vpn route or route propagation + diff --git a/common/version.tf b/common/version.tf index d29b6e2..07486a1 100644 --- a/common/version.tf +++ b/common/version.tf @@ -1,5 +1,5 @@ locals { - _module_version = "2.4.4" + _module_version = "2.4.5" _module_names = { "_main_" = "aws-vpc-setup" diff --git a/vpc-transit-gateway-association/self/associate.tf b/vpc-transit-gateway-association/self/associate.tf index 6c85abc..70fb1b5 100644 --- a/vpc-transit-gateway-association/self/associate.tf +++ b/vpc-transit-gateway-association/self/associate.tf @@ -88,7 +88,7 @@ resource "aws_ec2_transit_gateway_route_table_propagation" "vpc_self_common" { #--- resource "aws_ec2_transit_gateway_route_table_propagation" "vpn_vpc_self_own_rt" { provider = aws.self - for_each = { (var.transit_gateway_environment) = var.data_input.map_vpn_route_tables_self[var.transit_gateway_environment] } + for_each = var.vpn_route_prefix_list_name != null ? { (var.transit_gateway_environment) = var.data_input.map_vpn_route_tables_self[var.transit_gateway_environment] } : {} transit_gateway_attachment_id = aws_ec2_transit_gateway_vpc_attachment.vpc_attachment.id transit_gateway_route_table_id = each.value