Skip to content

Commit 08aec4b

Browse files
authored
Merge pull request #36657 from mjpytlak/BZ1986280b
BZ1986280: Added a kubelet config note about using valid values
2 parents c8c7ff9 + 4d1a37f commit 08aec4b

File tree

1 file changed

+12
-6
lines changed

1 file changed

+12
-6
lines changed

modules/create-a-kubeletconfig-crd-to-edit-kubelet-parameters.adoc

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,22 @@
77
[id="create-a-kubeletconfig-crd-to-edit-kubelet-parameters_{context}"]
88
= Creating a KubeletConfig CRD to edit kubelet parameters
99

10-
The kubelet configuration is currently serialized as an Ignition configuration, so it can be directly edited. However, there is also a new
11-
`kubelet-config-controller` added to the Machine Config Controller (MCC). This allows you to use a `KubeletConfig` custom resource (CR) to edit the kubelet parameters.
10+
The kubelet configuration is currently serialized as an Ignition configuration, so it can be directly edited. However, there is also a new `kubelet-config-controller` added to the Machine Config Controller (MCC). This lets you use a `KubeletConfig` custom resource (CR) to edit the kubelet parameters.
1211

13-
You should have one `KubeletConfig` CR for each machine config pool with all the config changes you want for that pool. If you are applying the same content to all the pools, you only need one `KubeletConfig` CR for all the pools.
12+
[NOTE]
13+
====
14+
As the fields in the `kubletConfig` object are passed directly to the kubelet from upstream Kubernetes, the kubelet validates those values directly. Invalid values in the `kubeletConfig` object might cause cluster nodes to become unavailable. For valid values, see the link:https://kubernetes.io/docs/reference/config-api/kubelet-config.v1beta1/[Kubernetes documentation].
15+
====
16+
17+
Consider the following guidance:
18+
19+
* Create one `KubeletConfig` CR for each machine config pool with all the config changes you want for that pool. If you are applying the same content to all of the pools, you need only one `KubeletConfig` CR for all of the pools.
1420

15-
You should edit an existing `KubeletConfig` CR to modify existing settings or add new settings instead of creating a new CR for each change. It is recommended to create a new CR only to modify a different machine config pool, or for changes that are intended to be temporary so that you can revert the changes.
21+
* Edit an existing `KubeletConfig` CR to modify existing settings or add new settings, instead of creating a CR for each change. It is recommended that you create a CR only to modify a different machine config pool, or for changes that are intended to be temporary, so that you can revert the changes.
1622

17-
You can create multiple `KubeletConfig` CRs, as needed, with a limit of 10 per cluster. For the first `KubeletConfig` CR, the MCO creates a machine config appended with `kubelet`. With each subsequent CR, the controller creates a new `kubelet` machine config with a numeric suffix. For example, if you have a `kubelet` machine config with a `-2` suffix, the next `kubelet` machine config is appended with `-3`.
23+
* As needed, create multiple `KubeletConfig` CRs with a limit of 10 per cluster. For the first `KubeletConfig` CR, the Machine Config Operator (MCO) creates a machine config appended with `kubelet`. With each subsequent CR, the controller creates another `kubelet` machine config with a numeric suffix. For example, if you have a `kubelet` machine config with a `-2` suffix, the next `kubelet` machine config is appended with `-3`.
1824

19-
If you want to delete the machine configs, you should delete them in reverse order to avoid exceeding the limit. For example, you should delete the `kubelet-3` machine config before deleting the `kubelet-2` machine config.
25+
If you want to delete the machine configs, delete them in reverse order to avoid exceeding the limit. For example, you delete the `kubelet-3` machine config before deleting the `kubelet-2` machine config.
2026

2127
[NOTE]
2228
====

0 commit comments

Comments
 (0)