-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patheks.tf
39 lines (36 loc) · 1.06 KB
/
eks.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
module "eks_cluster" {
source = "terraform-aws-modules/eks/aws"
cluster_name = var.cluster_name
cluster_version = var.cluster_version
subnets = module.vpc.private_subnets
enable_irsa = true
vpc_id = module.vpc.vpc_id
write_kubeconfig = false
manage_aws_auth = true
workers_group_defaults = {
root_volume_type = "gp2"
}
tags = {
Environment = "develop"
}
worker_groups = [
{
name = "worker-group-2"
instance_type = "t2.medium"
asg_max_size = 2
additional_security_group_ids = [aws_security_group.worker_group_1.id]
tags = [
{
"key" = "k8s.io/cluster-autoscaler/enabled"
"propagate_at_launch" = "false"
"value" = "true"
},
{
"key" = "k8s.io/cluster-autoscaler/${var.cluster_name}"
"propagate_at_launch" = "false"
"value" = "owned"
}
]
}
]
}