= Small Docker swarm Bare Metal Server Setup =

![ ](httpswww.redditstatic.com/desktop2x/img/renderTimingPixel.png)

I am planning to set up a small production-ready Docker Swarm cluster on three bare metal servers. I was hoping for personal accounts / feedback on their pains and successes in setting up such a deployment.

Recommendations like what O/S to use, patterns they found helpful, useful link, etc

thanks in advance!

RedHat has a lot of documentation and support for Podman, which is OCI complaint and works with rootless containers. It's also possible to get certified in it. They also have atomic builds of RedHat specifically designed to be a container Host OS.

However, Ubuntu has a lot of developer support. Depends on which direction you feel is better for your scenario.

RedHat also has free licenses of self-support for up to 16 servers. You could also land on CentOS Stream 8 and be just slightly ahead of RedHat enterprise linux in terms of updates, if you’d just rather avoid licensing. Being ahead of updates has its advantages and drawbacks. My favorite thing about RedHat is the OS remains very stagnant in terms of architecture. Ubuntu changes frequently.

**Guide to RedHat 8 Containers (Podman

httpsaccess.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html-single/building_running_and_managing_containers/index#con_characteristics-of-podman-buildah-and-skopeo_assembly_starting-with-containers

**Guide on RedHat UBI8, a container developed by RedHat to serve as the basis of your builds

httpscatalog.redhat.com/software/containers/ubi8-init/5c6aea74dd19c77a158f0892

I'm working on a 3-debian-node swarm with ansible myself right now

the swarm part is relatively trivial and quick to get up and running

the swarm takes over iptables and your usual rules don't apply anymore, you have to add a couple special ones

if you drain a node for whatever reason (reboot etc), once it's back, the replicated containers that were moved with drain don't come back on their own, you can

docker service update --force one by one, but that wouldand redo/redistribute the containers, so some requests could be dropped

the "hard" part is to set up your cluster-able services (reverse proxies, databases depends on what and how, and that's where you see that a lot of the same problems have been solved for Kubernetes (helper tools, plugins, documentation etc), with swarm you are on your own

volumes aren't replicated, you might need glusterfs, nfs etc


I’m planning on setting up 3 node clusters for Elasticsearch, RabbitMQ and MariaDB on these servers.

We don’t want to use Kubernetes as we are far from experts in setting that up. I was reading that docker swarm will make the deployment easier, but you have brought up some addition issues I need to consider.

Maybe going back a step, is it worth the complexity to add docker swarm to the tech stack or just manually setup everything using docker alone?

== About Community ==

Members

Online