forked from AmericanCouncils/AyamelResourceApiServer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
vagrantfile
37 lines (29 loc) · 1.29 KB
/
vagrantfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
VAGRANTFILE_API_VERSION = "2"
#this is the shell script that will run once the dev box is up - it just installs ansible
#then uses ansible to set up the vm
$provision_script = <<SCRIPT
apt-add-repository -y ppa:rquillo/ansible
apt-get update -y
apt-get install -y ansible
ansible-playbook /vagrant/dev-ansible/playbook.yml -i /vagrant/dev-ansible/hosts.cfg
SCRIPT
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "ubuntu/trusty64"
config.vm.hostname = "ayamel.vagrant.dev"
config.vm.define "ayamel.vagrant.dev"
config.vm.provider "virtualbox" do |v|
v.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
v.customize ["modifyvm", :id, "--natdnsproxy1", "on"]
v.memory = 2048
end
config.vm.provision "shell", inline: $provision_script, keep_color: true
config.ssh.forward_agent = true
config.ssh.private_key_path = [ '~/.vagrant.d/insecure_private_key', '~/.ssh/id_rsa' ]
# Create a private network, which allows host-only access to the machine
# using a specific IP.
config.vm.network :private_network, ip: "192.168.13.38"
# Try to forward a port for rabbitmqadmin http interface
config.vm.network "forwarded_port", guest: 15672, host: 15672
#forcing NFS for slightly better performance
config.vm.synced_folder ".", "/vagrant", nfs: true
end