DOCKER IN PRODUCTION WHICH ORCHESTRATOR TO USE, DOCKER SWARM OR KUBERNETES?

Using containers in the development area today is more than inevitable, even more so when we develop under the micro services architecture.

When using Docker it is very easy to make deployments, and the steps to perform are very few to have an application in production. It’s just building an image of your service and running a container with that image on your production server. But … what if we don’t have a single server, but 10 or 100 or even 10,000; there the work is complicated and a lot, because we would have to go from server to server applying configurations and pray to God that a server is not damaged, not to mention how we prepare for high traffic flows, in short, to guarantee a high availability. Just thinking about all that, we will most likely look like the following image:

This is where the orchestrators come in, which in simple terms are nothing more than a set of tools that will help us with the administration and monitoring of many containers/servers, all from one place.

There are many orchestrators, but today we will compare in 2 key aspects that differentiate the most when choosing between Docker Swarm and Kubernetes, the 2 most popular out there.

• Ease of implementation: At this point Docker swarm has an advantage and this is because you only need to have Docker installed on your servers and enable swarm mode, manual kubernetes configuration can in some cases be a little more complex, but in these cases it is It is possible to use tools such as EKS of AWS, although at an extra price.

• Scaling & Performance: In Docker swarm it is not possible to define an automatic scaling of our microservices compared to kubernetes, however, both have the quality that when defined the number of replicas we want for a task, the manager takes care of always comply with that rule, guaranteeing high availability of our services.

In terms of performance, it is a curious discussion because it has been shown that Docker Swarm can be up to 5 times faster for the execution of containers, however, after many tests, it was determined that the maximum limit that a manager of Docker swarm is 1,000 nodes and 30,000 containers compared to kubernetes that is capable of supporting up to 5,000 nodes managed by a single manager.

• Community and popularity: Currently kubernetes is part of the Cloud Native Computing Foundation (CNCF) and has a popularity level of more than 80% presence in articles and news related to cloud computing and even a large number of open source tools on github, which makes it the most popular orchestrator so far, this brings us the benefit of increasing the possibility of finding help in the community when there is a problem trying to implement it.

In conclusion, it is impossible to deny that kubernetes is the market leader in capacity and popularity and by far, however, implementing it in simple projects that only need high availability and speed is clearly an overkill. Docker swarm presents us with a simpler and faster work environment, although not as robust.

The decision is in your hands, and it depends on the type of project, but the information we have just given you can help you know which one to choose depending on your case, do not forget to share the blog 😉


(the reaction after implementing an orchestrator)


Posted by

Ever Luis Acosta – DevOps Developer