Skip to content

Instantly share code, notes, and snippets.

@arashkaffamanesh
Created August 16, 2020 13:00
Show Gist options
  • Save arashkaffamanesh/080bbca8e05e83225af644cccf304796 to your computer and use it in GitHub Desktop.
Save arashkaffamanesh/080bbca8e05e83225af644cccf304796 to your computer and use it in GitHub Desktop.
module "vpc" {
source = "terraform-aws-modules/vpc/aws"
version = "2.6.0"
name = var.cluster_name
cidr = "10.2.0.0/16"
azs = data.aws_availability_zones.available.names
private_subnets = ["10.2.0.0/20", "10.2.16.0/20", "10.2.32.0/20"]
public_subnets = ["10.2.48.0/20", "10.2.64.0/20", "10.2.80.0/20"]
enable_dns_hostnames = true
tags = {
"kubernetes.io/cluster/${local.cluster_name}" = "shared"
"kubernetes.io/role/elb" = "1"
"kubernetes.io/role/internal-elb" = "1"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment