diff --git a/_example/aws_managed/example.tf b/_example/aws_managed/example.tf index 9bd31e3..9303b2e 100644 --- a/_example/aws_managed/example.tf +++ b/_example/aws_managed/example.tf @@ -46,6 +46,16 @@ module "subnets" { ipv6_cidr_block = module.vpc.ipv6_cidr_block enable_ipv6 = false + extra_public_tags = { + "kubernetes.io/cluster/${module.eks.cluster_name}" = "owned" + "kubernetes.io/role/elb" = "1" + } + + extra_private_tags = { + "kubernetes.io/cluster/${module.eks.cluster_name}" = "owned" + "kubernetes.io/role/internal-elb" = "1" + } + public_inbound_acl_rules = [ { rule_number = 100 diff --git a/_example/aws_managed_with_fargate/example.tf b/_example/aws_managed_with_fargate/example.tf index 550ad38..93fe1a4 100644 --- a/_example/aws_managed_with_fargate/example.tf +++ b/_example/aws_managed_with_fargate/example.tf @@ -46,6 +46,16 @@ module "subnets" { ipv6_cidr_block = module.vpc.ipv6_cidr_block enable_ipv6 = false + extra_public_tags = { + "kubernetes.io/cluster/${module.eks.cluster_name}" = "owned" + "kubernetes.io/role/elb" = "1" + } + + extra_private_tags = { + "kubernetes.io/cluster/${module.eks.cluster_name}" = "owned" + "kubernetes.io/role/internal-elb" = "1" + } + public_inbound_acl_rules = [ { rule_number = 100 diff --git a/_example/complete/example.tf b/_example/complete/example.tf index e190445..6754bbd 100644 --- a/_example/complete/example.tf +++ b/_example/complete/example.tf @@ -34,7 +34,6 @@ module "subnets" { name = "${local.name}-subnets" environment = local.environment - tags = local.tags nat_gateway_enabled = true availability_zones = ["${local.region}a", "${local.region}b"] @@ -44,6 +43,16 @@ module "subnets" { type = "public-private" igw_id = module.vpc.igw_id + extra_public_tags = { + "kubernetes.io/cluster/${module.eks.cluster_name}" = "shared" + "kubernetes.io/role/elb" = "1" + } + + extra_private_tags = { + "kubernetes.io/cluster/${module.eks.cluster_name}" = "shared" + "kubernetes.io/role/internal-elb" = "1" + } + public_inbound_acl_rules = [ { rule_number = 100 diff --git a/_example/self_managed/example.tf b/_example/self_managed/example.tf index 1af703f..d6556de 100644 --- a/_example/self_managed/example.tf +++ b/_example/self_managed/example.tf @@ -34,7 +34,6 @@ module "subnets" { name = "${local.name}-subnets" environment = local.environment - tags = local.tags nat_gateway_enabled = true availability_zones = ["${local.region}a", "${local.region}b"] vpc_id = module.vpc.vpc_id @@ -42,6 +41,17 @@ module "subnets" { ipv6_cidr_block = module.vpc.ipv6_cidr_block type = "public-private" igw_id = module.vpc.igw_id + + extra_public_tags = { + "kubernetes.io/cluster/${module.eks.cluster_name}" = "shared" + "kubernetes.io/role/elb" = "1" + } + + extra_private_tags = { + "kubernetes.io/cluster/${module.eks.cluster_name}" = "shared" + "kubernetes.io/role/internal-elb" = "1" + } + public_inbound_acl_rules = [ { rule_number = 100