How to update RKE Kubelet to open read only port for Datadog to access metrics?

Hi,

I have a few RKE clusters that were spawned using the Rancher 2.4.4 UI. I need to get Datadog monitoring working on them, but the problem is that by default, RKE does not allow unauthenticated access to the Kubelet API which Datadog needs.

I have read this document: https://rancher.com/blog/2018/2018-07-16-how-to-deploy-datadog/ and it says that we’d have to add an extra arg read-only-port 10255 to Kubelet.

How do you update Kubelet on an RKE cluster spawned using the Rancher UI to add that arg?

Thanks,

Leo

Solved it. For anyone who lands on this thread, follow these steps:

  1. Open the cluster Dashboard UI
  2. On the top right, there are 3 dots. Click that > Edit
  3. On the Edit Cluster screen, scroll down to “Cluster Options”, there is a button on the right that says “Edit as YAML”. Click that. This will open the Kubernetes Options as a YAML file.

Under services, make the following addition/edits:

services:
  kubelet:
    extra_args:
      read-only-port: 10255

Click Save.

MAGIC.

Rancher is amazing.

And make sure to firewall that port.