A simple repository of my Ansible playbook
Reference : http://docs.ansible.com/
http://docs.ansible.com/ansible/intro_installation.html
You should install ansible by python package manager pip
$ sudo pip install ansible
You should give a look on this ssh2 implementation tool used by Ansible itself.
$ sudo pip install paramiko
Depending on your system, the way to install openssh can change. On my MAC it is simple as :
$ brew update
$ brew install openssh
Simply create and file /etc/ansible/hosts (and give you suffisant write rights on it)
$ sudo mkdir /etc/ansible
$ sudo touch /etc/ansible/hosts
$ sudo chmod a+rx /etc/ansible
$ sudo chmod a+rw /etc/ansible/hosts
And add your localhost (mainly for testing purpose for now)
$ sudo echo "
[targets]
localhost ansible_connection=local
" >> /etc/ansible/hosts
You can now issue a very first ansible command to localhost :
$ ansible localhost -m ping -e 'ansible_python_interpreter="/usr/bin/env python"'
localhost | SUCCESS => {
"changed": false,
"ping": "pong"
}