Skip to content

Commit

Permalink
Fixing terraform formatting issues
Browse files Browse the repository at this point in the history
  • Loading branch information
jnonino committed Jun 22, 2021
1 parent 5a80efe commit 05b32f0
Showing 1 changed file with 22 additions and 22 deletions.
44 changes: 22 additions & 22 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ resource "aws_vpc" "vpc" {
# A boolean flag to enable/disable DNS support in the VPC.
enable_dns_hostnames = true
# A boolean flag to enable/disable DNS hostnames in the VPC.
tags = merge(
var.additional_tags,
{
Name = "${var.name_prefix}-vpc"
},
)
tags = merge(
var.additional_tags,
{
Name = "${var.name_prefix}-vpc"
},
)

}

Expand All @@ -22,12 +22,12 @@ resource "aws_vpc" "vpc" {
#------------------------------------------------------------------------------
resource "aws_internet_gateway" "internet_gw" {
vpc_id = aws_vpc.vpc.id
tags = merge(
var.additional_tags,
{
Name = "${var.name_prefix}-internet-gw"
},
)
tags = merge(
var.additional_tags,
{
Name = "${var.name_prefix}-internet-gw"
},
)
}

#------------------------------------------------------------------------------
Expand All @@ -40,12 +40,12 @@ resource "aws_subnet" "public_subnets" {
availability_zone = element(var.availability_zones, count.index)
cidr_block = element(var.public_subnets_cidrs_per_availability_zone, count.index)
map_public_ip_on_launch = true
tags = merge(
var.additional_tags,
{
Name = "${var.name_prefix}-public-net-${element(var.availability_zones, count.index)}"
},
)
tags = merge(
var.additional_tags,
{
Name = "${var.name_prefix}-public-net-${element(var.availability_zones, count.index)}"
},
)
}

# Elastic IPs for NAT
Expand All @@ -67,10 +67,10 @@ resource "aws_nat_gateway" "nat_gw" {
subnet_id = var.single_nat ? aws_subnet.public_subnets.0.id : element(aws_subnet.public_subnets.*.id, count.index)

tags = merge(
var.additional_tags,
{
Name = "${var.name_prefix}-nat-gw-${element(var.availability_zones, count.index)}"
},
var.additional_tags,
{
Name = "${var.name_prefix}-nat-gw-${element(var.availability_zones, count.index)}"
},
)

depends_on = [
Expand Down

0 comments on commit 05b32f0

Please sign in to comment.