Commit f906e730 authored by Anton Babenko's avatar Anton Babenko Committed by GitHub

Merge pull request #13 from felixb/nat-gateway-tags

Add AZ to nat gateway name
parents c5c41556 1da7b4ee
...@@ -139,7 +139,7 @@ resource "aws_nat_gateway" "this" { ...@@ -139,7 +139,7 @@ resource "aws_nat_gateway" "this" {
allocation_id = "${element(aws_eip.nat.*.id, (var.single_nat_gateway ? 0 : count.index))}" allocation_id = "${element(aws_eip.nat.*.id, (var.single_nat_gateway ? 0 : count.index))}"
subnet_id = "${element(aws_subnet.public.*.id, (var.single_nat_gateway ? 0 : count.index))}" subnet_id = "${element(aws_subnet.public.*.id, (var.single_nat_gateway ? 0 : count.index))}"
tags = "${merge(var.tags, map("Name", format("%s", var.name)))}" tags = "${merge(var.tags, map("Name", format("%s-%s", var.name, element(var.azs, (var.single_nat_gateway ? 0 : count.index)))))}"
depends_on = ["aws_internet_gateway.this"] depends_on = ["aws_internet_gateway.this"]
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment