我正在使用EKS模块17.1.0版本创建一个terraform中的eks托管节点组,直到现在为止,指定的bootstrap_extra_args都是这样工作的
node_groups = [{
name = "${var.environment}-nodes"
desired_capacity = var.eks_cluster.desired_capacity
max_capacity = var.eks_cluster.max_capacity
min_capacity = var.eks_cluster.min_capacity
additional_security_group_ids = aws_security_group.nodes.id
instance_types = [var.eks_cluster.node_instance_type]
key_name = "$$$$$$"
bootstrap_extra_args = "/etc/eks/bootstrap.sh '${local.cluster_name}' --use-max-pods false --kubelet-extra-args '--max-pods=110'"
}]我已经创建了两个这样的集群,节点已经被创建,最大的豆荚设置为110。这两个星系团都在美国东部-2号。
我现在正试图在中国地区创建一个集群,cn-西北-1,相同的配置只将最大吊舱设置为35,我似乎无法让它飞得更高。
节点类型: t3a.large实例
注意:我还尝试用包含以下用户数据脚本的launch_template启动中国中的节点,并读取脚本,没有发现错误,结果是相同的。
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="//"
--//
Content-Type: text/x-shellscript; charset="us-ascii"
#!/bin/bash -xe
/etc/eks/bootstrap.sh '${cluster_name}' --use-max-pods false --kubelet-extra-args '--max-pods=110'
--//--这就引出了这样的问题,在中国中,企业管理的节点组设置有一点不同吗?如果没有一些我似乎找不到的疯狂的解决办法,我想要做的是什么吗?
发布于 2022-05-25 07:46:19
经过进一步的测试,与terraform文档相反,bootstrap_extra_args的上述定义不起作用,而且terraform不识别参数,即使它不会抛出任何错误。正确的方法是通过Launch_template在userdata中设置以下脚本
bootstrap_extra_args = "${local.cluster_name} --b64-cluster-ca ${module.eks.cluster_certificate_authority_data} --apiserver-endpoint ${module.eks.cluster_endpoint} --use-max-pods false"userdatascript.sh.tpl
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="//"
--//
Content-Type: text/x-shellscript; charset="us-ascii"
#!/bin/bash
set -ex
/etc/eks/bootstrap.sh ${bootstrap_extra_args}
--//--如果不包括- max -pods,它将自动将最大吊舱设置为110。
https://stackoverflow.com/questions/72348667
复制相似问题