Skip to content

Commit bb6f11c

Browse files
committed
Simplify eksctl configuration
Signed-off-by: Manuel Alejandro de Brito Fontes <[email protected]>
1 parent 02786a4 commit bb6f11c

File tree

1 file changed

+24
-21
lines changed

1 file changed

+24
-21
lines changed

eks-cluster.yaml

Lines changed: 24 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -56,34 +56,33 @@ cloudWatch:
5656
privateCluster:
5757
enabled: false
5858
additionalEndpointServices:
59-
- "autoscaling"
60-
- "logs"
59+
- "autoscaling"
60+
- "logs"
6161

6262
managedNodeGroups:
6363
- name: workspaces
6464
desiredCapacity: 1
6565
minSize: 1
66-
maxSize: 3
66+
maxSize: 10
6767
# because of AWS addons
6868
disableIMDSv1: false
6969
# Please configure the size of the volume and additional features
7070
# https://eksctl.io/usage/schema/#nodeGroups-volumeType
7171
# https://aws.amazon.com/es/ebs/pricing/
72-
volumeSize: 100
72+
volumeSize: 300
7373
volumeType: gp3
7474
volumeIOPS: 6000
7575
volumeThroughput: 500
7676
ebsOptimized: true
7777
# Use private subnets for nodes
7878
# https://eksctl.io/usage/vpc-networking/#use-private-subnets-for-initial-nodegroup
7979
privateNetworking: true
80-
ami: ami-0ea449d16eb31a003
80+
ami: ami-0a5735f238643d4c5
81+
8182
tags:
8283
# EC2 tags required for cluster-autoscaler auto-discovery
8384
k8s.io/cluster-autoscaler/enabled: "true"
8485
k8s.io/cluster-autoscaler/gitpod: "owned"
85-
k8s.io/cluster-autoscaler/node-template/label/purpose: workspaces
86-
k8s.io/cluster-autoscaler/node-template/taint/dedicated: "workspaces:NoSchedule"
8786
iam:
8887
attachPolicyARNs: &attachPolicyARNs
8988
- arn:aws:iam::aws:policy/AmazonEC2ContainerRegistryReadOnly
@@ -107,17 +106,19 @@ managedNodeGroups:
107106
108107
declare -a LABELS=(
109108
eks.amazonaws.com/nodegroup="${NODEGROUP}"
110-
purpose="${NODEGROUP}"
109+
gitpod.io/workload_workspaces=true
111110
)
112111
113-
export USE_MAX_PODS=false
114112
export KUBELET_EXTRA_ARGS="$(printf -- "--max-pods=110 --node-labels=%s" $(IFS=$','; echo "${LABELS[*]}"))"
115113
/etc/eks/bootstrap.sh ${CLUSTERNAME}
116114
117-
instanceTypes: [r5n.xlarge, r5n.2xlarge]
118-
# Create a spot nodegroup
119-
# Please change to false for production
120-
spot: true
115+
spot: false
116+
# https://eksctl.io/usage/instance-selector/
117+
#instanceSelector:
118+
# vCPUs: 8
119+
# memory: 64Gib
120+
# or use a custom list
121+
instanceTypes: ["r5.2xlarge", "r5.4xlarge"]
121122

122123
- name: services
123124
desiredCapacity: 1
@@ -136,12 +137,12 @@ managedNodeGroups:
136137
# Use private subnets for nodes
137138
# https://eksctl.io/usage/vpc-networking/#use-private-subnets-for-initial-nodegroup
138139
privateNetworking: true
139-
ami: ami-0ea449d16eb31a003
140+
ami: ami-0a5735f238643d4c5
141+
140142
tags:
141143
# EC2 tags required for cluster-autoscaler auto-discovery
142144
k8s.io/cluster-autoscaler/enabled: "true"
143145
k8s.io/cluster-autoscaler/gitpod: "owned"
144-
k8s.io/cluster-autoscaler/node-template/label/purpose: services
145146
iam:
146147
attachPolicyARNs: *attachPolicyARNs
147148
withAddonPolicies: *withAddonPolicies
@@ -155,14 +156,16 @@ managedNodeGroups:
155156
156157
declare -a LABELS=(
157158
eks.amazonaws.com/nodegroup="${NODEGROUP}"
158-
purpose="${NODEGROUP}"
159+
gitpod.io/workload_services=true
159160
)
160161
161-
export USE_MAX_PODS=false
162162
export KUBELET_EXTRA_ARGS="$(printf -- "--max-pods=110 --node-labels=%s" $(IFS=$','; echo "${LABELS[*]}"))"
163163
/etc/eks/bootstrap.sh ${CLUSTERNAME}
164164
165-
instanceTypes: [r5n.xlarge, r5n.2xlarge]
166-
# Create a spot nodegroup
167-
# Please change to false for production
168-
spot: true
165+
spot: false
166+
# https://eksctl.io/usage/instance-selector/
167+
#instanceSelector:
168+
# vCPUs: 4
169+
# memory: 16Gib
170+
# or use a custom list
171+
instanceTypes: ["r5.xlarge", "r5.2xlarge"]

0 commit comments

Comments
 (0)