I am deploying my application which contains three services by using Docker Swarm. As what i’ve read so far, Docker Swarm has a load-balancer to distribute container over Worker nodes automatically based on some internal factors. That is cool! but what i really need is a load-balancer which uses a set of parameters provided by me to distribute containers. Is it possible or it is too ambitious?
A set of parameters i mentioned here is obtained by running a script or code which calculate cpu usage, bandwidth, etc. Then its results will be passed to the load-balancer for distribution decision.
But to code your own scheduler using swarm mode is not possible, fx. what do you want to happen if the node you assigned containers, dies, then swarm will try to reschedule those containers to other nodes by itself.
You could try and use https://kubernetes.io/, which will provide a more advanced scheduler
thanks man, i will take a look at your recommended sites yeah … i want to customize a bit in the default scheduler, hope it is not too hard, otherwise i gotta find another way