Install Ansible on Ubuntu 16.04 using pip

Installing ansible on ubuntu

Ansible requires python for to operate, there are multiple ways to install Ansible , but it is better to install with python installation .

  • You will need Python2 or Python3
  • python pip and install Ansible
  • First update repository using apt-get update
  • Check if Python is installed , if installed
  • Install Python3-pip
  • Install Ansible using Pip install and verify

$ sudo apt-get update

Updating Repository

Check if python3 is already installed

$apt list –installed |grep -i python

Checking if python is installed, we can use “grep” as filter and “-i” option ignores the case

As you can see python3 is installed

We need to install PIP using following command

$sudo apt-get install python3-pip

Installing pyhton3-pip

Installing Ansible using Pip

$pip3 install ansible

Verifying Ansible installation

$ansible –version