Installing and Running Ansible on Linux

Ansible is a tool for managing remote computers via secure shell (ssh). This quick how-to is based on the Ansible Installation page.


To install Ansible on Debian Mint:

  1. If you don’t have pip installed, run: sudo easy_install pip
  2. Run: sudo pip install paramiko PyYAML Jinja2 httplib2 six
  3. Install Ansible by running: sudo pip install ansible
  4. Run: sudo mkdir /etc/ansible
  5. Run: sudo vim /etc/ansible/hosts
  6. Insert the following lines (replacing the example host with the hosts you want to manage):

Writing Scripts

Ansible has its own weird YAML (yet another markup language) based scripting language for writing programs called playbooks (see the Intro to Playbooks). Create your script with a text editor, save it in a file (e.g. playbook.yml), and run it with:

ansible-playbook playbook.yml

About jimbelton

I'm a software developer, and a writer of both fiction and non-fiction, and I blog about movies, books, and philosophy. My interest in religious philosophy and the search for the truth inspires much of my writing.
This entry was posted in programming and tagged , , , , , , . Bookmark the permalink.

Leave a Comment

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s