Skip to content

Latest commit

 

History

History
58 lines (44 loc) · 7.82 KB

README.md

File metadata and controls

58 lines (44 loc) · 7.82 KB

tf_aws_subnets

Simple terraform module for AWS private and public subnets

  • Switching between NAT gateway and NAT instances easily
  • Multi-AZ support

Requirements

Name Version
terraform >= 0.12

Providers

Name Version
aws n/a

Modules

No modules.

Resources

Name Type
aws_network_acl.public resource
aws_route.gateway_id resource
aws_route.nat_gateway resource
aws_route.nat_instance resource
aws_route_table.default resource
aws_route_table_association.default resource
aws_subnet.default resource

Inputs

Name Description Type Default Required
azs Availability Zones string "ap-northeast-1a,ap-northeast-1c" no
gateway_ids Internet Gateway IDs that is used as default routes when creating public subnets list [] no
instance_ids List identifier of EC2 instances list [] no
map_public_ip_on_launch Specify true to indicate that instances launched into the subnet should be assigned a public IP address. bool "false" no
nat_gateway_ids List identifier of a VPC NAT gateway list [] no
network_acl_egress Egress network ACL rules list(map(string))
[
{
"action": "allow",
"cidr_block": "0.0.0.0/0",
"from_port": 0,
"protocol": "-1",
"rule_no": 100,
"to_port": 0
}
]
no
network_acl_ingress Egress network ACL rules list(map(string))
[
{
"action": "allow",
"cidr_block": "0.0.0.0/0",
"from_port": 0,
"protocol": "-1",
"rule_no": 100,
"to_port": 0
}
]
no
subnet_cidrs The CIDR block of the subnets string n/a yes
subnet_name Subnets name string "dynamic" no
subnet_tags A map of tags to assign to the resource map {} no
vpc_id VPC ID string n/a yes

Outputs

Name Description
route_table_ids List of route table IDs
subnet_arns List of subnet ARNs
subnet_ids List of subnet IDs