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
In terraform 11, we would be able to access the single nat instance with ${module.nat.instance_ids[0]} . Since the 0.12 upgrade, terraform would output an error for this in the sense that this value "is a tuple with 1 element" instead of a single string value. The workaround was to have it like element("${module.nat.instance_ids[0]}",0) to access the single instance id
Let me know if you need further details.
The text was updated successfully, but these errors were encountered:
Hello,
We have configured the NAT module like this:
module "nat" {
source = "github.com/terraform-community-modules/tf_aws_nat"
name = "nat-test-${var.environment_tag}"
instance_type = "t2.nano"
instance_count = "1"
aws_key_name = var.key_name
public_subnet_ids = [aws_subnet.public-subnet.id]
private_subnet_ids = [aws_subnet.subnet-backend[0].id, aws_subnet.subnet-backend[1].id]
vpc_security_group_ids = [aws_security_group.nat.id]
az_list = [data.aws_availability_zones.available.names[0]]
subnets_count = "1"
ssh_bastion_user = "user"
ssh_bastion_host = aws_instance.bastion.public_ip
aws_private_key = file(var.private_key_path)
}
In terraform 11, we would be able to access the single nat instance with ${module.nat.instance_ids[0]} . Since the 0.12 upgrade, terraform would output an error for this in the sense that this value "is a tuple with 1 element" instead of a single string value. The workaround was to have it like element("${module.nat.instance_ids[0]}",0) to access the single instance id
Let me know if you need further details.
The text was updated successfully, but these errors were encountered: