blob: b67c7fafec27037e61f8a2c6dc4ffc2b370be413 [file] [log] [blame]
Vagrant.configure("2") do |config|
# base image
config.vm.box = "ubuntu/trusty64"
# share the folder
config.vm.synced_folder "../", "/home/vagrant/service-profile"
config.vm.synced_folder "../../xos", "/home/vagrant/xos", create: true
config.vm.synced_folder "../../xos_services", "/home/vagrant/xos_services", create: true
config.vm.synced_folder "../../xos_libraries", "/home/vagrant/xos_libraries", create: true
config.vm.synced_folder ".", "/vagrant", disabled: true
# set the frontend vm
config.vm.define "frontend" do |d|
d.vm.network "forwarded_port", guest: 9999, host: 9999
d.vm.network "forwarded_port", guest: 6379, host: 6379
d.vm.network "private_network", ip: "192.168.46.100"
d.vm.provider "virtualbox" do |vb|
vb.memory = "2048"
end
end
config.vm.provision "shell", privileged: false, inline: <<-SHELL
sudo apt-get update
sudo apt-get install -y apt-transport-https ca-certificates git
sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
echo deb https://apt.dockerproject.org/repo ubuntu-trusty main | sudo tee /etc/apt/sources.list.d/docker.list
sudo apt-get update
sudo apt-get install -y git docker-engine python-pip
sudo pip install docker-compose
sudo groupadd docker
sudo usermod -aG docker vagrant
SHELL
end