K3s: x509: certificate is valid for 127.0.0.1, PublicIPv4, PublicIPv6 not Privatev4

Hello I am trying to install a k3s Cluster on Hetzner Cloud with [Hetzner CCM](https://github.com/hetznercloud/hcloud-cloud-controller-manager/blob/main/deploy/ccm-networks.yaml)

I use the this commands to install the Server:

Install k3s

$ curl -sfL https://get.k3s.io | INSTALL_K3S_EXEC="--flannel-backend=none --disable traefik --disable servicelb --tls-san=$(hostname -I | awk '{print $2}') --node-name=$(hostname -f) --disable-cloud-controller --cluster-cidr=10.244.0.0/16 -  --kubelet-arg="cloud-provider=external" --node-taint="node-role.kubernetes.io/master:NoSchedule"" sh -s -

Install Hetzner CCM

$ kubectl -n kube-system create secret generic hcloud --from-literal=token=HETZNER_API_SECRET --from-literal="network=k3s"
$ kubectl apply -f https://github.com/hetznercloud/hcloud-cloud-controller-manager/releases/latest/download/ccm-networks.yaml

Install Calico:

$ curl https://raw.githubusercontent.com/projectcalico/calico/v3.24.5/manifests/calico.yaml -O
$ kubectl apply -f calico.yaml

Then after a time everything is up exept the pod from metric-server. When I try to get logs from a pod I get the Cert error:

$ kubectl logs metrics-server-5c8978b444-87d5j -n kube-system
Error from server: Get "https://10.29.0.3:10250/containerLogs/kube-system/metrics-server-5c8978b444-87d5j/metrics-server": x509: certificate is valid for 127.0.0.1, 49.12.184.241, 2a01:4f8:c012:f0a8::1, not 10.29.0.3

Can any one tell me what I am doing wrong?

Did you manage to solve this?

I have the same issue, only with the flannel backend on . I do not only have an issue with the metrics server, but all the logs cannot be accessed. also the nodes cannot be accessed from Lens. Kubectl get nodes works normally. I have added the requested ip address to the secrets but nothing changes.