Skip to content

Commit e3bde7c

Browse files
committed
fix: align terraform config with deployed infrastructure
1 parent 7ecf9e2 commit e3bde7c

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

terraform/eks.tf

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ resource "aws_eks_cluster" "this" {
33
role_arn = aws_iam_role.eks_cluster.arn
44
version = var.cluster_version
55

6+
bootstrap_self_managed_addons = false
7+
68
vpc_config {
79
subnet_ids = aws_subnet.private[*].id
810
endpoint_public_access = true

terraform/vpc.tf

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,9 @@ locals {
1414

1515
azs = slice(data.aws_availability_zones.available.names, 0, local.az_count)
1616

17-
# Derive subnet ranges from the configurable VPC CIDR.
18-
subnet_cidrs = cidrsubnets(var.vpc_cidr, 4, 4, 4, 4)
19-
20-
public_subnet_cidrs = slice(local.subnet_cidrs, 0, local.az_count)
21-
private_subnet_cidrs = slice(local.subnet_cidrs, local.az_count, local.az_count * 2)
17+
# Match the deployed subnet layout (explicit /24 blocks within the VPC CIDR).
18+
public_subnet_cidrs = ["10.0.1.0/24", "10.0.2.0/24"]
19+
private_subnet_cidrs = ["10.0.10.0/24", "10.0.20.0/24"]
2220
}
2321

2422
resource "aws_vpc" "this" {

0 commit comments

Comments
 (0)