From: Alfredo Deza Date: Mon, 14 Nov 2016 18:25:26 +0000 (-0500) Subject: testing: parse and set DISABLE_SYNCED_FOLDER in vagrant file X-Git-Tag: v2.0~1^2~9 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=f6c788b4d11cae20f6f90a346feef5bc8b659776;p=ceph-ansible.git testing: parse and set DISABLE_SYNCED_FOLDER in vagrant file Signed-off-by: Alfredo Deza --- diff --git a/Vagrantfile b/Vagrantfile index 8bbc3a675..3957d4c23 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -30,6 +30,7 @@ DOCKER = settings['docker'] USER = settings['ssh_username'] ASSIGN_STATIC_IP = !(BOX == 'openstack' or BOX == 'linode') +DISABLE_SYNCED_FOLDER = settings.fetch('vagrant_disable_synced_folder', false) ansible_provision = proc do |ansible| if DOCKER then @@ -126,9 +127,14 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| config.ssh.private_key_path = settings['ssh_private_key_path'] config.ssh.username = USER - # Faster bootup. Disable if you need this for libvirt - config.vm.provider :libvirt do |v,override| - override.vm.synced_folder '.', SYNC_DIR, disabled: true + # Faster bootup. Disables mounting the sync folder for libvirt and virtualbox + if DISABLE_SYNCED_FOLDER + config.vm.provider :virtualbox do |v,override| + override.vm.synced_folder '.', SYNC_DIR, disabled: true + end + config.vm.provider :libvirt do |v,override| + override.vm.synced_folder '.', SYNC_DIR, disabled: true + end end if BOX == 'openstack'