Last active
December 19, 2015 23:08
-
-
Save gonz/6032530 to your computer and use it in GitHub Desktop.
Local ansible vagrantfile
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
$script = <<SCRIPT | |
set -e | |
if [ ! -f /usr/local/bin/ansible-playbook ] | |
then | |
sudo apt-get update | |
sudo apt-get -y install python-setuptools python-dev | |
sudo easy_install pip | |
sudo pip install ansible | |
fi | |
ansible-playbook /vagrant/provisioning/vagrant.yml -i /vagrant/provisioning/development --connection=local | |
SCRIPT | |
Vagrant.configure("2") do |config| | |
# ... | |
config.vm.provision :shell, :inline => $script | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment