I would like to know how could i setup a load balancer at the kubernetes level so my services points to the pods that has the more ram/cpu ressources available and not randomly.
It would be co-existing with a Horizontal Pod Autoscaler.
As of today i have an ingress pointing to my NodePort service
It would be better if it could work localy with minikube without needing to be on a cloud provider.
If not, im using OVH as my Kubernetes cloud provider.
Thanks for any infos
Q: services points to the pods that has the more ram/cpu ressources available
There is no such feature in Kubernetes at the moment.
But you can switch kube-proxy to ipvs mode and it allows you to use the following balancing algorithm:
- rr: round-robin
- lc: least connection
- dh: destination hashing
- sh: source hashing
- sed: shortest expected delay
- nq: never queue
Calico also supports it.