Vagrant: correct init script so profiles work; cosmic support

Had to increase the memory allowed to the machine as it appeared to be
running out
This commit is contained in:
Peter Barker 2018-10-19 17:20:33 +11:00 committed by Andrew Tridgell
parent 84d7160128
commit 33a215e8be
2 changed files with 29 additions and 6 deletions

View File

@ -29,7 +29,7 @@ sudo resize2fs /dev/sda1
usermod -a -G dialout $VAGRANT_USER usermod -a -G dialout $VAGRANT_USER
echo "calling pre-reqs script..." echo "calling pre-reqs script..."
/vagrant/Tools/scripts/install-prereqs-ubuntu.sh -y sudo -H -u $VAGRANT_USER /vagrant/Tools/scripts/install-prereqs-ubuntu.sh -y
echo "...pre-reqs script done... initvagrant.sh continues." echo "...pre-reqs script done... initvagrant.sh continues."
# run-in-terminal-window uses xterm: # run-in-terminal-window uses xterm:

33
Vagrantfile vendored
View File

@ -6,10 +6,12 @@
# xterm # X11 forwarding should work # xterm # X11 forwarding should work
# sim_vehicle.py --debug --gdb # sim_vehicle.py --debug --gdb
# sim_vehicle.py --valgrind # sim_vehicle.py --valgrind
# cd /vagrant && ./waf configure --board=px4-v2 && ./waf build --target=bin/ardusub # time (cd /vagrant && ./waf configure --board=px4-v2 && ./waf build --target=bin/ardusub) # ~17 minutes
# cd /vagrant ./waf configure --board=navio2 && ./waf build --target=bin/arduplane # time (cd /vagrant && ./waf configure --board=fmuv2 && ./waf build --target=bin/ardusub) # ~9 minutes
# cd /vagrant ./Tools/autotest/sim_vehicle.py -v ArduPlane # should test JSBSim # time (cd /vagrant && ./waf configure --board=fmuv3 && ./waf build --target=bin/ardusub) # ~ minutes (after building fmuv2)
# cd /vagrant ./Tools/autotest/autotest.py build.APMrover2 drive.APMrover2 # time (cd /vagrant && ./waf configure --board=navio2 && ./waf build --target=bin/arduplane)
# time (cd /vagrant && ./Tools/autotest/sim_vehicle.py --map --console -v ArduPlane -f jsbsim # should test JSBSim)
# time (cd /vagrant && ./Tools/autotest/autotest.py build.APMrover2 drive.APMrover2)
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing! # Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2" VAGRANTFILE_API_VERSION = "2"
@ -25,7 +27,7 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
# vb.gui = true # vb.gui = true
# #
# # Use VBoxManage to customize the VM. For example to change memory: # # Use VBoxManage to customize the VM. For example to change memory:
vb.customize ["modifyvm", :id, "--memory", "2048"] vb.customize ["modifyvm", :id, "--memory", "3192"]
vb.customize ["modifyvm", :id, "--ioapic", "on"] vb.customize ["modifyvm", :id, "--ioapic", "on"]
vb.customize ["modifyvm", :id, "--cpus", "2"] vb.customize ["modifyvm", :id, "--cpus", "2"]
# Make some effort to avoid clock skew # Make some effort to avoid clock skew
@ -115,5 +117,26 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
end end
end end
# 18.10 bleeding edge
config.vm.define "cosmic32", autostart: false do |cosmic32|
config.vm.box = "ubuntu/cosmic32"
config.vm.provision :shell, path: "Tools/vagrant/initvagrant.sh"
config.vm.provider "virtualbox" do |vb|
vb.name = "ArduPilot (cosmic32)"
vb.gui = true
end
end
# 18.10 bleeding edge
config.vm.define "cosmic64", autostart: false do |cosmic64|
config.vm.box = "ubuntu/cosmic64"
config.vm.provision :shell, path: "Tools/vagrant/initvagrant.sh"
config.vm.provider "virtualbox" do |vb|
vb.name = "ArduPilot (cosmic64)"
vb.gui = true
end
end
end end