+ Demeter EIP, and NAT Gateway for private instances
* Updating naming scheme in gateway.tf & route-table.tf Should be more clear what each block is meant for
This commit is contained in:
parent
fa91971e45
commit
86a0122042
@ -15,3 +15,10 @@ resource "aws_eip" "gamma_eip" {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
resource "aws_eip" "demeter_eip" {
|
||||||
|
vpc = true
|
||||||
|
tags = {
|
||||||
|
Name = "NAT Gateway EIP"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@ -1,7 +1,16 @@
|
|||||||
resource "aws_internet_gateway" "athens_gateway" {
|
resource "aws_internet_gateway" "athens_internet_gateway" {
|
||||||
vpc_id = aws_vpc.athens_vpc.id
|
vpc_id = aws_vpc.athens_vpc.id
|
||||||
|
|
||||||
tags = {
|
tags = {
|
||||||
Name = "Athens Common Internet Gateway"
|
Name = "Athens Common Internet Gateway"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
resource "aws_nat_gateway" "athens_nat_gateway" {
|
||||||
|
allocation_id = aws_eip.demeter_eip.id
|
||||||
|
subnet_id = aws_subnet.crete_subnet.id
|
||||||
|
|
||||||
|
tags = {
|
||||||
|
Name = "Demeter - Crete' NAT"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@ -3,7 +3,7 @@ resource "aws_route_table" "crete_route_table" {
|
|||||||
route {
|
route {
|
||||||
# ????
|
# ????
|
||||||
cidr_block = "0.0.0.0/0"
|
cidr_block = "0.0.0.0/0"
|
||||||
gateway_id = aws_internet_gateway.athens_gateway.id
|
gateway_id = aws_internet_gateway.athens_internet_gateway.id
|
||||||
}
|
}
|
||||||
tags = {
|
tags = {
|
||||||
Name = "Crete Route Table"
|
Name = "Crete Route Table"
|
||||||
@ -14,3 +14,4 @@ resource "aws_route_table_association" "crete_gateway_association" {
|
|||||||
subnet_id = aws_subnet.crete_subnet.id
|
subnet_id = aws_subnet.crete_subnet.id
|
||||||
route_table_id = aws_route_table.crete_route_table.id
|
route_table_id = aws_route_table.crete_route_table.id
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user