Hi Team,
I have started applying terraform scripts… I have an idea how can i configure the subnets with naming like sub_dev-public-1, sub_dev-public-2 & sub_dev-public-3…
But i would like to configure like sub_dev-public-a, sub_dev-public-b & sub_dev-public-c
Here, my resource block… Can you please advise me the syntax help?
data "aws_availability_zones" "available" {}
resource "aws_subnet" "tf_public_subnet" {
count = 3
vpc_id = "${aws_vpc.tf_vpc.id}"
cidr_block = "${var.public_cidrs[count.index]}"
map_public_ip_on_launch = "true"
availability_zone = "${data.aws_availability_zones.available.names[count.index]}"
tags {
Name = "sub_dev-public-${count.index + 1}"
}
}