How to configure k3s through Rancher Desktop

526 views Asked by At

I have a dedicated server running Ubuntu and Rancher Desktop.

I'd like to be able to access the Kubernetes cluster (K3S) from another computer in the same network. In doing so, after I've setup my kube configuration, I'm getting an error.

Unable to connect to the server: x509: certificate is valid for 10.43.0.1, 127.0.0.1, 192.168.5.15, ::1, fec0::5055:55ff:fe8e:47db, not 192.168.1.8

Passing the following config through to K3S should solve my problem

INSTALL_K3S_EXEC="--tls-san 192.168.1.8"

Reading through Rancher Desktop documentation, I found a potential solution. Based on the documentation I should be able to pass config through to k3s via the Provisional Script for Rancher Desktop. It is still unclear to me as how I do this for the K3S configurations.

1

There are 1 answers

0
Fred On

The k3s repository has this issue with a proposed solution at https://github.com/k3s-io/k3s/issues/3369

"SANs should be added to the dynamiclistener cert on demand, based on the SNI hostname requested by the client. Try running the following on the server:"

curl -vk --resolve 172.31.13.97:6443:127.0.0.1  https://172.31.13.97:6443/ping