eksctl로 노드그룹 추가 방법
조회 1,024 · 댓글 0
cat << EOF > add-mngs-spot.yaml
---
apiVersion: eksctl.io/v1alpha5
kind: ClusterConfig
managedNodeGroups:
- name: mng-spot-4vcpu-16gb
amiFamily: AmazonLinux2
desiredCapacity: 2
minSize: 0
maxSize: 4
spot: true
instanceTypes:
- m4.xlarge
- m5.xlarge
- m5a.xlarge
- m5ad.xlarge
- m5d.xlarge
- t2.xlarge
- t3.xlarge
- t3a.xlarge
iam:
withAddonPolicies:
autoScaler: true
cloudWatch: true
albIngress: true
privateNetworking: true
taints:
- key: spotInstance
value: "true"
effect: PreferNoSchedule
labels:
alpha.eksctl.io/cluster-name: eksworkshop-eksctl
alpha.eksctl.io/nodegroup-name: mng-spot-4vcpu-16gb
intent: apps
tags:
alpha.eksctl.io/nodegroup-name: mng-spot-4vcpu-16gb
alpha.eksctl.io/nodegroup-type: managed
k8s.io/cluster-autoscaler/node-template/label/intent: apps
k8s.io/cluster-autoscaler/node-template/taint/spotInstance: "true:PreferNoSchedule"
- name: mng-spot-8vcpu-32gb
amiFamily: AmazonLinux2
desiredCapacity: 1
minSize: 0
maxSize: 2
spot: true
instanceTypes:
- m4.2xlarge
- m5.2xlarge
- m5a.2xlarge
- m5ad.2xlarge
- m5d.2xlarge
- t2.2xlarge
- t3.2xlarge
- t3a.2xlarge
iam:
withAddonPolicies:
autoScaler: true
cloudWatch: true
albIngress: true
privateNetworking: true
taints:
- key: spotInstance
value: "true"
effect: PreferNoSchedule
labels:
alpha.eksctl.io/cluster-name: eksworkshop-eksctl
alpha.eksctl.io/nodegroup-name: mng-spot-8vcpu-32gb
intent: apps
tags:
alpha.eksctl.io/nodegroup-name: mng-spot-8vcpu-32gb
alpha.eksctl.io/nodegroup-type: managed
k8s.io/cluster-autoscaler/node-template/label/intent: apps
k8s.io/cluster-autoscaler/node-template/taint/spotInstance: "true:PreferNoSchedule"
metadata:
name: eksworkshop-eksctl
region: ${AWS_REGION}
version: "1.21"
EOF
eksctl create nodegroup --config-file=add-mngs-spot.yaml로그인 후 답글을 남길 수 있습니다.