diff options
author | Ed Warnicke <eaw@cisco.com> | 2016-02-02 17:47:17 -0800 |
---|---|---|
committer | Gerrit Code Review <gerrit@fd.io> | 2016-02-03 14:49:37 +0000 |
commit | eeee9e2b1820ae1ca194ba0093d49519b66558f8 (patch) | |
tree | 6f1e1cbe26bd3cbef25c985acfb3b9328f941b70 /build-root/vagrant/Vagrantfile | |
parent | c28b4745911de6834a89343f40c35cafab59a706 (diff) |
Switched vagrant for ~/git/vpp to /vpp
build-root/vagrant/Vagrantfile
was always mounting the vpp into /vpp
Now rather than cloning it and building,
we just use it as mounted.
In order to let folks know what happened,
a README.moved is copied into the ~/git/vpp
so folks know what happened.
In addition to make it easier for folks
to do commits from withing the vagrant,
we install git-review, and copy in the
users .gitconfig and .gnupg directory.
A couple of notes about this. VMWare goes much
much faster in all cases. Virtualbox is a
bit slower in the very first run (without ccache).
One of the benefits of using the mounted /vpp though
is that after your first vagrant up, you always
have access to the .ccache, as it lives
outside the vagrant, and so in steady state
everything is faster.
Change-Id: I2cd2c28181b3d7e664240dfe2249b5be3f1b9241
Signed-off-by: Ed Warnicke <eaw@cisco.com>
Diffstat (limited to 'build-root/vagrant/Vagrantfile')
-rw-r--r-- | build-root/vagrant/Vagrantfile | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/build-root/vagrant/Vagrantfile b/build-root/vagrant/Vagrantfile index f00233d632c..f4021659878 100644 --- a/build-root/vagrant/Vagrantfile +++ b/build-root/vagrant/Vagrantfile @@ -13,6 +13,22 @@ Vagrant.configure(2) do |config| config.vm.provision 'shell', path: 'bootstrap.ubuntu1404.sh' end + # Add .gnupg dir in so folks can sign patches + # Note, as gnupg puts socket files in that dir, we have + # to be cautious and make sure we are dealing with a plain file + homedir = File.expand_path("~/") + Dir["#{homedir}/.gnupg/**/*"].each do |fname| + if File.file?(fname) + destname = fname.sub(Regexp.escape("#{homedir}/"),'') + config.vm.provision "file", source: fname, destination: destname + end + end + + # Copy in the .gitconfig if it exists + if File.file?(File.expand_path("~/.gitconfig")) + config.vm.provision "file", source: "~/.gitconfig", destination: ".gitconfig" + end + # vagrant-cachier caches apt/yum etc to speed subsequent # vagrant up # to enable, run |