Use the proper provider upgrade mechanism in V1 VM
This commit is contained in:
parent
acbd024fa2
commit
d53e189063
|
@ -100,14 +100,20 @@ module VagrantPlugins
|
||||||
new.vm.usable_port_range = self.auto_port_range if self.auto_port_range
|
new.vm.usable_port_range = self.auto_port_range if self.auto_port_range
|
||||||
|
|
||||||
if self.boot_mode
|
if self.boot_mode
|
||||||
# Enable the GUI if the boot mode is GUI.
|
new.vm.provider :virtualbox do |vb|
|
||||||
new.vm.providers[:virtualbox].config.gui = (self.boot_mode.to_s == "gui")
|
# Enable the GUI if the boot mode is GUI.
|
||||||
|
vb.gui = (self.boot_mode.to_s == "gui")
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
# If we have VM customizations, then we enable them on the
|
# If we have VM customizations, then we enable them on the
|
||||||
# VirtualBox provider on the new VM.
|
# VirtualBox provider on the new VM.
|
||||||
self.customizations.each do |customization|
|
if !self.customizations.empty?
|
||||||
new.vm.providers[:virtualbox].config.customize(customization)
|
new.vm.provider :virtualbox do |vb|
|
||||||
|
self.customizations.each do |customization|
|
||||||
|
vb.customize(customization)
|
||||||
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
# Re-define all networks.
|
# Re-define all networks.
|
||||||
|
|
Loading…
Reference in New Issue