mirror of
https://github.com/dragonheim/gagent.git
synced 2025-05-24 10:06:48 -07:00
fix: [CI SKIP] Converting various files to the same basic format.
This commit is contained in:
parent
8f8ac47155
commit
0cf7f36f17
9 changed files with 129 additions and 132 deletions
|
@ -1,38 +1,38 @@
|
|||
# variable "vpc_id" {}
|
||||
|
||||
data "aws_vpc" "selected" {
|
||||
id = var.vpc_id
|
||||
id = var.vpc_id
|
||||
}
|
||||
|
||||
variable "regional_cidr_blocks" {
|
||||
description = "A simple map of subnets used by region"
|
||||
type = map
|
||||
default = {
|
||||
"us-west-2a-private" = "10.172.64.0/23",
|
||||
"us-west-2b-private" = "10.172.66.0/23",
|
||||
"us-west-2a-public" = "10.172.68.0/26",
|
||||
"us-west-2b-public" = "10.172.68.64/26",
|
||||
"us-east-1a-private" = "10.172.0.0/23",
|
||||
"us-east-1b-private" = "10.172.2.0/23",
|
||||
"us-east-1a-public" = "10.172.4.0/26",
|
||||
"us-east-1b-public" = "10.172.4.64/26"
|
||||
}
|
||||
description = "A simple map of subnets used by region"
|
||||
type = map
|
||||
default = {
|
||||
"us-west-2a-private" = "10.172.64.0/23",
|
||||
"us-west-2b-private" = "10.172.66.0/23",
|
||||
"us-west-2a-public" = "10.172.68.0/26",
|
||||
"us-west-2b-public" = "10.172.68.64/26",
|
||||
"us-east-1a-private" = "10.172.0.0/23",
|
||||
"us-east-1b-private" = "10.172.2.0/23",
|
||||
"us-east-1a-public" = "10.172.4.0/26",
|
||||
"us-east-1b-public" = "10.172.4.64/26"
|
||||
}
|
||||
}
|
||||
|
||||
resource "aws_subnet" "aza-private" {
|
||||
depends_on = [data.aws_vpc.selected]
|
||||
vpc_id = data.aws_vpc.id
|
||||
availability_zone = format("%sa", var.region)
|
||||
cidr_block = var.regional_cidr_blocks[
|
||||
format("%sa-private", var.region)
|
||||
]
|
||||
tags = merge(
|
||||
var.extra_tags,
|
||||
{
|
||||
Name = "aza-private"
|
||||
tier = "private"
|
||||
}
|
||||
)
|
||||
depends_on = [data.aws_vpc.selected]
|
||||
vpc_id = data.aws_vpc.id
|
||||
availability_zone = format("%sa", var.region)
|
||||
cidr_block = var.regional_cidr_blocks[
|
||||
format("%sa-private", var.region)
|
||||
]
|
||||
tags = merge(
|
||||
var.extra_tags,
|
||||
{
|
||||
Name = "aza-private"
|
||||
tier = "private"
|
||||
}
|
||||
)
|
||||
}
|
||||
|
||||
# resource "aws_subnet" "aza-public" {
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
variable "extra_tags" {
|
||||
description = "Tags required on all resources"
|
||||
type = map
|
||||
default = {
|
||||
"org" = "dragonheim"
|
||||
"service" = "gagent"
|
||||
"maintained_by" = "jwells@dragonheim.net"
|
||||
}
|
||||
description = "Tags required on all resources"
|
||||
type = map
|
||||
default = {
|
||||
"org" = "dragonheim"
|
||||
"service" = "gagent"
|
||||
"maintained_by" = "jwells@dragonheim.net"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,22 +2,22 @@ variable "region" {}
|
|||
variable "provider_alias" {}
|
||||
|
||||
variable "regional_vpc_cidr" {
|
||||
description = "A simple map of VPC subnets used by region"
|
||||
type = map
|
||||
default = {
|
||||
"us-west-2" = "10.172.64.0/19",
|
||||
"us-east-1" = "10.172.0.0/19",
|
||||
}
|
||||
description = "A simple map of VPC subnets used by region"
|
||||
type = map
|
||||
default = {
|
||||
"us-west-2" = "10.172.64.0/19",
|
||||
"us-east-1" = "10.172.0.0/19",
|
||||
}
|
||||
}
|
||||
|
||||
resource "aws_vpc" "gagent" {
|
||||
instance_tenancy = "default"
|
||||
enable_dns_support = true
|
||||
cidr_block = var.regional_vpc_cidr[var.region]
|
||||
tags = merge(
|
||||
var.extra_tags,
|
||||
{
|
||||
Name = "gagent"
|
||||
}
|
||||
)
|
||||
instance_tenancy = "default"
|
||||
enable_dns_support = true
|
||||
cidr_block = var.regional_vpc_cidr[var.region]
|
||||
tags = merge(
|
||||
var.extra_tags,
|
||||
{
|
||||
Name = "gagent"
|
||||
}
|
||||
)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue