Zsolt Haraszti | 3d16353 | 2016-09-08 15:57:32 -0700 | [diff] [blame] | 1 | # -*- mode: ruby -*- |
| 2 | # vi: set ft=ruby : |
| 3 | |
| 4 | Vagrant.configure(2) do |config| |
| 5 | |
| 6 | if (/cygwin|mswin|mingw|bccwin|wince|emx/ =~ RUBY_PLATFORM) != nil |
| 7 | config.vm.synced_folder ".", "/voltha", mount_options: ["dmode=700,fmode=600"] |
| 8 | else |
| 9 | config.vm.synced_folder ".", "/voltha" |
| 10 | end |
| 11 | |
| 12 | config.vm.define "voltha" do |d| |
| 13 | d.ssh.forward_agent = true |
Zsolt Haraszti | 29d10af | 2016-12-10 10:38:32 -0800 | [diff] [blame^] | 14 | d.vm.box = "ubuntu/xenial64" |
Zsolt Haraszti | 3d16353 | 2016-09-08 15:57:32 -0700 | [diff] [blame] | 15 | d.vm.hostname = "voltha" |
| 16 | d.vm.network "private_network", ip: "10.100.198.220" |
| 17 | d.vm.provision :shell, path: "ansible/scripts/bootstrap_ansible.sh" |
| 18 | d.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /voltha/ansible/voltha.yml -c local" |
Zsolt Haraszti | cfd15e5 | 2016-09-22 23:18:17 -0700 | [diff] [blame] | 19 | d.vm.provision :shell, inline: "cd /voltha && source env.sh && make install-protoc && chmod 777 /tmp/fluentd" |
Zsolt Haraszti | 3d16353 | 2016-09-08 15:57:32 -0700 | [diff] [blame] | 20 | d.vm.provider "virtualbox" do |v| |
Zsolt Haraszti | a54f2ac | 2016-09-21 15:54:15 -0700 | [diff] [blame] | 21 | v.memory = 4096 |
Zsolt Haraszti | 3d16353 | 2016-09-08 15:57:32 -0700 | [diff] [blame] | 22 | end |
| 23 | end |
| 24 | |
| 25 | if Vagrant.has_plugin?("vagrant-cachier") |
| 26 | config.cache.scope = :box |
| 27 | end |
| 28 | |
| 29 | end |