Taint eks节点组 [英] Taint eks node-group

查看:121
本文介绍了Taint eks节点组的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个包含2个节点组的集群:实时一般.我只希望能够容忍 realtime 的Pod能够在 realtime 集群中的节点上运行. 我的方法是 tainment 相关节点,并向要注册到该节点的pod添加 tolerance .当我试图污染一个节点组时,我陷入了死胡同.在我的情况下,我有一个弹性的EKS节点组,即,节点的数量不断增加和减少.如何配置组,以使一个组中的节点在创建时被污染?

I have a cluster with 2 node groups: real time and general. I would like only pods which tolerate affinity real time to be able to run on nodes from the real time cluster. My approach was to taint the relevant nodes and add toleration to the pod that I want to register to that node. I came into a dead-end when I was trying to taint a node-group. In my case I have an EKS node group that is elastic, i.e. nodes are increasing and decreasing in numbers constantly. How can I configure the group so that nodes from one group will be tainted upon creation?

推荐答案

我假设您正在通过CloudFormation创建nodeGroup?

I assume you're creating your nodeGroup via CloudFormation?

在这种情况下,可以为LaunchConfig添加--kubelet-extra-args --register-with-taints={key}={value}:NoSchedule作为$ {BootstrapArguments}

If that is the case you can add --kubelet-extra-args --register-with-taints={key}={value}:NoSchedule as your ${BootstrapArguments} for your LaunchConfig

/etc/eks/bootstrap.sh ${clusterName} ${BootstrapArguments}

这样,每当您向上或向下扩展群集时,都会生成带有适当污点的Node.

That way, whenever you scale up or down your cluster, a Node will be spawned with the appropriate taint.

这篇关于Taint eks节点组的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆