The Ansible package is available on all major Linux distributions. In this section, we will install it onto both Ubuntu and CentOS machines. The Ansible 2.5 release was used at the time of developing this book, and it provides support for both Python 2.6 and Python 2.7. Also, starting from version 2.2, Ansible provides a tech preview for Python 3.5+.
Installing Ansible on Linux
On RHEL and CentOS
You will need to have the EPEL repository installed and enabled before installing Ansible. To do so, use the following command:
sudo yum install epel-release
Then, proceed with the Ansible package installation, as shown in the following command:
sudo yum install Ansible