summaryrefslogtreecommitdiffstats
path: root/build-root/vagrant/Vagrantfile
diff options
context:
space:
mode:
authorDave Wallace <dwallacelf@gmail.com>2017-01-26 21:42:00 -0500
committerDamjan Marion <dmarion.lists@gmail.com>2017-02-02 13:42:56 +0000
commited0e49c51841e84c72a5bb2c6d538ee779b734d4 (patch)
tree7ad7c16dc967afd07f3a99ee6a436fe924407a87 /build-root/vagrant/Vagrantfile
parent460bc633b131d2001bb81d7c2ad5a51ec177ac93 (diff)
Update default Vagrant box to Ubuntu 16.04, VPP-616
- Make puppetlabs/ubuntu-16.04-64-nocm the default box - Enable x11 forwarding - Install x11-utils required for emacs to work over X11 - Refactor run.sh - Add VPP_VAGRANT_POST_BUILD environment variable to allow selection of installing VPP or run "make test". - Fix dependencies in src/vppapigen.am Change-Id: I0ec054fdc83feb71ca8396df53ed02bf82ecd7e7 Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Diffstat (limited to 'build-root/vagrant/Vagrantfile')
-rw-r--r--build-root/vagrant/Vagrantfile21
1 files changed, 15 insertions, 6 deletions
diff --git a/build-root/vagrant/Vagrantfile b/build-root/vagrant/Vagrantfile
index 9e03a84efc4..b463d646092 100644
--- a/build-root/vagrant/Vagrantfile
+++ b/build-root/vagrant/Vagrantfile
@@ -3,21 +3,29 @@
Vagrant.configure(2) do |config|
- # Pick the right distro and bootstrap, default is ubuntu1404
- distro = ( ENV['VPP_VAGRANT_DISTRO'] || "ubuntu1404")
+ # Pick the right distro and bootstrap, default is ubuntu1604
+ distro = ( ENV['VPP_VAGRANT_DISTRO'] || "ubuntu1604")
if distro == 'centos7'
config.vm.box = "puppetlabs/centos-7.2-64-nocm"
config.ssh.insert_key = false
- else
+ elsif distro == 'ubuntu1404'
config.vm.box = "puppetlabs/ubuntu-14.04-64-nocm"
+ else
+ config.vm.box = "puppetlabs/ubuntu-16.04-64-nocm"
end
config.vm.box_check_update = false
config.vm.provision :shell, :path => File.join(File.dirname(__FILE__),"update.sh")
config.vm.provision :shell, :path => File.join(File.dirname(__FILE__),"build.sh"), :args => "/vpp vagrant"
- config.vm.provision :shell, :path => File.join(File.dirname(__FILE__),"install.sh"), :args => "/vpp"
- config.vm.provision :shell, :path => File.join(File.dirname(__FILE__),"clearinterfaces.sh")
- config.vm.provision :shell, :path => File.join(File.dirname(__FILE__),"run.sh")
+
+ post_build = ( ENV['VPP_VAGRANT_POST_BUILD'] )
+ if post_build == "test"
+ config.vm.provision "shell", inline: "echo Testing VPP; cd /vpp; make test"
+ elsif post_build == "install"
+ config.vm.provision :shell, :path => File.join(File.dirname(__FILE__),"install.sh"), :args => "/vpp"
+ config.vm.provision :shell, :path => File.join(File.dirname(__FILE__),"clearinterfaces.sh")
+ config.vm.provision :shell, :path => File.join(File.dirname(__FILE__),"run.sh")
+ end
# Add .gnupg dir in so folks can sign patches
# Note, as gnupg puts socket files in that dir, we have
@@ -61,6 +69,7 @@ Vagrant.configure(2) do |config|
vmram=(ENV['VPP_VAGRANT_VMRAM'] || 4096)
config.ssh.forward_agent = true
+ config.ssh.forward_x11 = true
config.vm.provider "virtualbox" do |vb|
vb.customize ["modifyvm", :id, "--ioapic", "on"]