Professional Documents
Culture Documents
tags = {
Name = "Guilherme VPC"
BuildWith = "terraform"
}
}
tags = {
Name = "Public Subnet"
BuildWith = "terraform"
}
}
tags = {
Name = "Private Subnet"
BuildWith = "terraform"
}
}
tags = {
Name = "Internet Gateway"
BuildWith = "terraform"
}
}
# adding an elastic IP
resource "aws_eip" "elastic_ip" {
vpc = true
depends_on = ["aws_internet_gateway.internet_gateway"]
}
# creating the NAT gateway
resource "aws_nat_gateway" "nat" {
allocation_id = "${ aws_eip.elastic_ip.id }"
subnet_id = "${ aws_subnet.public_subnet.id }"
depends_on = ["aws_internet_gateway.internet_gateway"]
}
tags {
Name = "Private Subnet Route Table"
BuildWith = "terraform"
}
}