scripts/vagrant: sync spdk common for all providers

We have to sync spdk sources regardless of used provider.
Can also sync tools if available.

Change-Id: Ia149a68d632abadf69d20d7c34c6d7f158e2d7cb
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.gerrithub.io/422285
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
This commit is contained in:
Karol Latecki 2018-08-14 15:36:43 +02:00 committed by Jim Harris
parent 75327bc67e
commit a257328d69

View File

@ -71,18 +71,6 @@ Vagrant.configure(2) do |config|
vb.memory = "#{vmram}" vb.memory = "#{vmram}"
vb.cpus = "#{vmcpu}" vb.cpus = "#{vmcpu}"
# rsync the spdk directory if provision hasn't happened yet
unless File.exist? (".vagrant/machines/default/virtualbox/action_provision")
if spdk_dir != "none"
config.vm.synced_folder "#{spdk_dir}", "/home/vagrant/spdk_repo/spdk", type: "rsync", rsync__auto: false
end
# Copy in the user's tools if they exists
if File.directory?(File.expand_path("~/vagrant_tools"))
config.vm.synced_folder "~/vagrant_tools", "/home/vagrant/tools", type: "rsync", rsync__auto: false
end
end
nvme_disk = 'nvme.vdi' nvme_disk = 'nvme.vdi'
unless File.exist? (nvme_disk) unless File.exist? (nvme_disk)
vb.customize ["createhd", "--filename", nvme_disk, "--variant", "Fixed", "--size", "1024"] vb.customize ["createhd", "--filename", nvme_disk, "--variant", "Fixed", "--size", "1024"]
@ -119,12 +107,15 @@ Vagrant.configure(2) do |config|
# Optional field if we want use other storage pools than default # Optional field if we want use other storage pools than default
# libvirt.storage_pool_name = "vm" # libvirt.storage_pool_name = "vm"
end
# rsync the spdk directory if provision hasn't happened yet # rsync the spdk directory if provision hasn't happened yet
unless File.exist? (".vagrant/machines/default/virtualbox/action_provision") if spdk_dir != "none"
if spdk_dir != "none" config.vm.synced_folder "#{spdk_dir}", "/home/vagrant/spdk_repo/spdk", type: "rsync", rsync__auto: false
config.vm.synced_folder "#{spdk_dir}", "/home/vagrant/spdk_repo/spdk", type: "rsync" end
end
end # Copy in the user's tools if they exists
if File.directory?(File.expand_path("~/vagrant_tools"))
config.vm.synced_folder "~/vagrant_tools", "/home/vagrant/tools", type: "rsync", rsync__auto: false
end end
end end