Simply put, its a an open source DevOps tool/IT automation engine that automates provisioning, configuration management, application deployment, orchestration, and many other IT processes.
Off course there exists other alternatives to #Ansible, including:
✅ Rudder
✅ SaltStack
✅ Puppet Enterprise
✅ Chef
✅ CFEngine
✅ Gitlab CI
✅ Jenkins
But after consulting a few buddies, i got to learn that its pretty easy to get started.
My Setup:
Lets discuss a few terminologies:
✅The Ansible control node is the machine we’ll use to connect to and control the Ansible hosts over SSH.
✅An Ansible host is any machine that your Ansible control node is configured to automate.
To install ansible on your Control node, simply run:
sudo apt install ansible sshpass -y
Once ansible is installed, you need to define the hosts in an Inventory file.
Simply put, its a file that contains information about the servers Ansible controls, and its typically located at /etc/ansible/hosts.
See how you can define : servers, ssh username & Password
Earlier, i mentioned i created my first playbook.
This is a file containing a series of tasks to be executed on a remote server.
Consider the following playbook, it would come in handy when i have a fresh ubuntu install & need to install a couple of necessary tools.
In the screenshot above, under the 'play recap' , you can see the status change for each server to 2. Meaning we installed both tools.
If we run the same playbook again, we can see the 'change' status indicated "0", meaning the tools have already been installed.