-
Notifications
You must be signed in to change notification settings - Fork 716
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
RFE: Make kubeadm Config easy to consume #1881
Comments
expose converters on the side of public types and don't use internal types as a stepping stone for conversion. which roughly translates to A) don't use api-machinery or B) redesign api-machinery. |
@fabriziopandini @timothysc @ncdc this is a problem for: kubeadm has the same problem of consuming the kubelet config. if v1beta1 is gone but the users still use it it should just fail. then it's the responsibility of the user to convert to the new preferred type. discussions about making all components (e.g. kubelet, apiserver etc) exposing conversion on their CLI or via a serving endpoint has seen objection thus far. but frankly we didn't have enough discussions. as a first step i think CAPI should stop including the kubeadm type as a field and use the following pattern instead:
then the kubeadm binary can be used to validate all referenced configs and use the first one that passes (we might have to add a command / flag for that). if the user is feeding a config that is out of support there is no way for us to support it on the fly, unless CAPI bundles older kubeadm binaries for the sake of conversion. |
So controller-runtime has built some tooling around conversions using only external types. I don't know how re-usable it might be for the purposes of kubeadm, and the dependency tree could present quite a few issues at least until kubeadm moves out of tree. |
reducing the priority as this is currently non-blocking, given v1beta1 is going to be available until 1.20. |
some of the complexities were discussed in today's cluster-api meeting. mitigating the lack of feedback from cloud init on verification:the CABPK configuration object is user created, or at least the user maintains the part about the kubeadm config. this also means the kubeadm config can be verified on the user side. i do not know if CABPK dynamically modifies the kubeadm config the user provides. prior a CAPI deployment that uses CABPK, can the kubeadm config be passed to a kubeadm binary, say in makefile rule that downloads the binary from the internet? this will ensure that the kubeadm config is validated before it reaches cloud init. same can be done for the component configs with their respective binaries, and once they support validation on the CLI side. propagating kubeadm config fieldsthe other reason the kubeadm config is embedded is due to it's values are used by the cluster-api in other locations. this problem can solved with templates, which is not pretty but it can work:
of course, these proposals are attempting to avoid version pining. |
Issues go stale after 90d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-testing, kubernetes/test-infra and/or fejta. |
/remove-lifecycle stale |
Issues go stale after 90d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-contributor-experience at kubernetes/community. |
/remove-lifecycle stale |
cluster api now implements a new method for consuming the kubeadm types by forking them, but eventually they can consume a vendored version. |
@neolit123 Is there a reason to not consider a staging repository and publish kubeadm that way as a go module? |
it's complicated:
we already have plans to make the API vendorable via #2316 or #1949, but this cannot happen soon. public converters are a whole different topic, but i will not comment on that in this post. |
Kubeadm config should be more easy to consume for higher-level tools like CAPI.
The v1beta3 is going to fix inconsistencies on omitempty/+optional and the lack of ObjectMeta, but still, the fact that there are multiple versions of the Kubeadm config is a problem for higher-level tools like CAPI.
How can we make the Kubeadm config more easy to consume?
The text was updated successfully, but these errors were encountered: