k0sproject / k0smotron

k0smotron
https://docs.k0smotron.io/
Other
430 stars 40 forks source link

loadbalancer service for pod control plane also matches etcd pods #592

Closed Schnitzel closed 1 month ago

Schnitzel commented 1 month ago

the service kmc-[clustername]-lb has the following targets:

  selector:
    app: k0smotron
    cluster: [clustername]
    cluster.x-k8s.io/cluster-name: [clustername]

unfortunately this also matches the etcd pods and not only the control plane pods, causing the infra loadbalancer to freak out (in case of hetzner it never becomes healthy, as the etcd pods don't know what to do with the requests).

interestingly the etcd pods have an component: etcd while the controlplane pods do not have an component label, making it actually hard to match the service only to the controlplane pods.