For the last couple of weeks I’ve been playing with Ansible, a very powerful automation tool that lets you configure, and deploy applications to multiple remote servers with a single command.
Sounds easy, right? The answer is yes…but only after you get ansible to a point where it does what you want it to do. In this post I will explain how to use ansible to install a cluster of Tomcat 7 containers balanced by an HAProxy. I want to make clear that the purpose of this post is not to explain how ansible works. You should first take a look at the ansible documentation to get familiar with the basic commands a configuration files we’ll be using for this project.
The following diagram illustrates the system that we are trying to build: