You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 3, 2023. It is now read-only.
Hi,
in the vpc module there is an error concerning the number of NAT Gateways created for each public network.
resource "aws_nat_gateway" "main" {
count = "${length(var.internal_subnets)}"
allocation_id = "${element(aws_eip.nat..id, count.index)}"
subnet_id = "${element(aws_subnet.external..id, count.index)}"
depends_on = ["aws_internet_gateway.main"]
}
resource "aws_eip" "nat" {
count = "${length(var.internal_subnets)}"
vpc = true
}
var.internal_subnets should be var.external_subnets
in my example I have 6 internal networks and 3 public networks and end up with 6 NAT Gateways
The text was updated successfully, but these errors were encountered: