Installing Ansible from source on Ubuntu

Installing Ansible from source is the best way to make sure that you have all the latest features and bug fixes. Fortunately, it’s nice and easy to do too.

First, make sure you have any dependencies installed:

sudo apt-get install python-2.7 python-yaml python-paramiko python-jinja2 python-httplib2

Next, download the code:

git clone --recursive

Then we want to install it:

cd ansible && make && sudo make install

Now, Ansible should be installed

which ansible 
=> /usr/local/bin/ansible

Michael is a polyglot software engineer, committed to reducing complexity in systems and making them more predictable. Working with a variety of languages and tools, he shares his technical expertise to audiences all around the world at user groups and conferences. You can follow @mheap on Twitter

Thoughts on this post

Nick 2016-07-06

You’re missing a “git submodule update –init –recursive” after the git clone.

michael 2016-07-06

Thanks, I’ve updated the post to add –recursive to the clone. The use of submodules was added after the publication of this post

It seems that some additional dependencies are needed: python-sphinx and python-setuptools

Leave a comment?

Leave a Reply