Privacy Policy
Snippets index

  Running ansible from Windows host

Install MobaXterm

download link: http://mobaxterm.mobatek.net/download.html

From MobaXterm local terminal, install needed pre-requisites

apt-get install python python-paramiko python-crypto gcc-g++ wget openssh python-setuptools
python -m ensurepip

Install Ansible

pip install ansible==1.9.4

Download provisioning files

apt-get install git
git clone https://github.com/myaccount/mydeployment.git

cd mydeployment/myproject
ansible-playbook -v -i hosts --limit=HOST provision.yml --user=USER -k

where USER is a sudoer for HOST

FINALLY, add to the project folder the file "ansible.cfg" as follows:

[ssh_connection]
control_path = /tmp

[defaults]
remote_tmp = /tmp/${USER}/ansible