Skip to content

scalereal/terraform-aws-vpc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

terraform-aws-vpc

Terraform Module for AWS VPC and subnets creation.

Requirements

Name Version
terraform ~> 1.2
aws ~> 4.0

Providers

Name Version
aws 4.22.0

Modules

No modules.

Resources

Name Type
aws_db_subnet_group.db_subnet_group resource
aws_egress_only_internet_gateway.egress_only_gateway resource
aws_eip.nat resource
aws_internet_gateway.internet_gateway resource
aws_nat_gateway.nat_gw resource
aws_route.private_egress_gateway_ipv6 resource
aws_route.private_nat_gateway resource
aws_route.public_internet_gateway resource
aws_route.public_internet_gateway_ipv6 resource
aws_route_table.private_nat resource
aws_route_table.public resource
aws_route_table_association.private_nat resource
aws_route_table_association.public resource
aws_subnet.database resource
aws_subnet.private resource
aws_subnet.public resource
aws_vpc.vpc resource

Inputs

Name Description Type Default Required
availability_zones A list of availability zones in the region list(string) n/a yes
aws_profile AWS Region for develop infra string "default" no
aws_region AWS Region for develop infra string "us-east-1" no
cidr_block CIDR for dev VPC string n/a yes
database_ipv4_subnets A list all the database IPv4 subnets in the VPC list(string) n/a yes
enable_dns_hostnames Enable/Disable DNS hostnames in the VPC bool true no
enable_dns_support Enable/Disable DNS support in the VPC bool true no
enable_ipv6_egw Enable/Disable Egress-only Gateway to enable internet access in private IPv6 subnet bool true no
enable_nat_gateway Enable/Disable nat gateway in public subnets to enable internet access in private subnet bool true no
enable_vpc_ipv6 Enables IPv6 Support in the VPC bool false no
env Deployment Environment string n/a yes
instance_tenancy A tenancy option for instances in the VPC string "default" no
private_ipv4_subnets A list all the private IPv4 subnets in the VPC list(string) n/a yes
public_ipv4_subnets A list all the public IPv4 subnets in the VPC list(string) n/a yes
service_name Name of the service string n/a yes
tags Tags for VPC map(string) {} no

Outputs

Name Description
aws_db_subnet_group_name VPC database subnet group name
cidr_block VPC CIDR block
database_subnets_ids VPC database subnet ids
id VPC ID
ipv6_cidr_block VPC IPv6 CIDR block
private_subnets_ids VPC private subnet ids
public_subnet_ids VPC public subnet ids