-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support kubeletExtraConfig in managed node groups #4459
Comments
Thanks for opening the issue @janeklb. For future folks who didn't realise we already have this for unmanaged nodegroups atm 😅 https://eksctl.io/usage/schema/#nodeGroups-kubeletExtraConfig. The feature sounds reasonable to me 👍 |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
We have this in our doc:
I think there is a reason for that because managed nodegroups don't allow for this to be passed in? |
I guess we could make something like, if it's defined, we set override, and pass in the necessary config. That could work, and would bring together the way we handle extra configure in |
That would make kubelet config management (for managed node groups) a lot easier! |
The only that will be required however, is that a custom AMI is set. I can't do anything unless that is done, because only then will the Managed Nodegroups not merge all the user data. @janeklb |
Okay, so after rummaging in the code, the following will be done:
overrideBootstrapCommand: |
#!/bin/bash
/etc/eks/bootstrap.sh my-cluster-name \
--kubelet-extra-args <parsedargshere> \
|
So... I can't make this work without awslabs/amazon-eks-ami#873 being a thing in the bootstrap.sh of a managed nodegroup. Without that, anything I would do with the extra config is just overwritten. I tried doing something like this: #!/bin/sh
set -ex
KUBELET_CONFIG=/etc/kubernetes/kubelet/kubelet-config.json
TMP_KUBE_CONF='/tmp/kubelet-conf-temp.json'
KUBELET_CONFIG_EXTRA='/tmp/kubelet-conf-extra.json'
echo '%s' > ${KUBELET_CONFIG_EXTRA}
echo "eksctl: merging user options into kubelet-config.json"
trap 'rm -f ${TMP_KUBE_CONF} ${KUBELET_CONFIG_EXTRA}' EXIT
jq -s '.[0] + .[1]' "${KUBELET_CONFIG}" "${KUBELET_CONFIG_EXTRA}" > "${TMP_KUBE_CONF}"
mv "${TMP_KUBE_CONF}" "${KUBELET_CONFIG}"
/etc/eks/bootstrap.sh %s As a userdata script. Which works very well actually. Where I could have parsed the config flag and then translate each and every json value to a If AWS deems this a nice feature to have, we can come back to this issue. Until then, sadly, this is blocked. |
FWIW I submitted the necessary modification to the bootstrap script as a PR here. |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
This issue was closed because it has been stalled for 5 days with no activity. |
Yep, we also could use kubeletExtraConfigs for managed nodegroups, to work around aws/containers-roadmap#1847 |
What feature/behaviour/change do you want?
Support
kubeletExtraConfig
in managed node groupsWhy do you want this feature?
In order to specify extra kubelet configuration features, you need to use
overrideBootstrap
and use--kubelet-extra-args
etc. This is rather cumbersome and so it would be preferable to use something like node groups'kubeletExtraConfig
field for managed node groups.Summary
"I guess we could make something like, if it's defined, we set override, and pass in the necessary config. That could work, and would bring together the way we handle extra configure in eksctl with nodegroups."
The text was updated successfully, but these errors were encountered: