terraform-aws-vpc-peering
terraform-aws-vpc-peering copied to clipboard
VPC Peering routes should be preserved if they don't change.
Describe the Feature
Current code for adding routes is based on count
https://github.com/cloudposse/terraform-aws-vpc-peering/blob/47c6e51bf449de36cc7f487317bdab2d0b5aadaa/main.tf#L51-L67
Changing tags can possible result in changing count order and removal of actually using peering routing.
Expected Behavior
If matching pattern tag for a route is changed then only associated route table for this exact peering should be changed.
Use Case
It's possible that downtime will happen during terraform apply when tags will be changed on route.
Describe Ideal Solution
aws_route
inside this module should use for_each
which would prevent temporary routing changes