Running Ansible on Vagrant
On the previous post i was talking about how to run Ansible on AWS. IF you dont have acess to AWS or your solution runs on bare metal you still can run ansible on Vagrant and have an environment to test your playbooks.
Once you download and install Vagrant, you just need pick up my vagrant file and them you ready to have ansible running :-)
So you download the Vagrantfile and put it into a directory in your machine, them you gonna run:
$ vagrant up
$ vagrant ssh
That`s it, you are ready to have fun. Keep in mind for this vagrant file im using a shared folder where im putting my playbooks, if you dont want this just comment the line on the Vagrantfile.
From Vagrant 1.7.2 to Vagrant 1.7.4 there was some issues with Windows and RSYNC, if you having this kind of trouble, follow this instructions and you will be able to run on windows without issues.
If you want my sample playbook, check it out on my GitHub. Once you are into the box via SSH, you can just do:
$ ansible-playbook book.yml
Cheers,
Diego Pacheco
Once you download and install Vagrant, you just need pick up my vagrant file and them you ready to have ansible running :-)
So you download the Vagrantfile and put it into a directory in your machine, them you gonna run:
$ vagrant up
$ vagrant ssh
That`s it, you are ready to have fun. Keep in mind for this vagrant file im using a shared folder where im putting my playbooks, if you dont want this just comment the line on the Vagrantfile.
From Vagrant 1.7.2 to Vagrant 1.7.4 there was some issues with Windows and RSYNC, if you having this kind of trouble, follow this instructions and you will be able to run on windows without issues.
If you want my sample playbook, check it out on my GitHub. Once you are into the box via SSH, you can just do:
$ ansible-playbook book.yml
Cheers,
Diego Pacheco