mirror of
https://github.com/vagrant-libvirt/vagrant-libvirt.git
synced 2025-02-25 18:55:27 -06:00
bug fixes for qemu_use_session
This commit is contained in:
parent
29ce8443b1
commit
99371fee2b
@ -129,6 +129,7 @@ module VagrantPlugins
|
|||||||
# If we have a box, take the path from the domain volume and set our storage_prefix.
|
# If we have a box, take the path from the domain volume and set our storage_prefix.
|
||||||
# If not, we dump the storage pool xml to get its defined path.
|
# If not, we dump the storage pool xml to get its defined path.
|
||||||
# the default storage prefix is typically: /var/lib/libvirt/images/
|
# the default storage prefix is typically: /var/lib/libvirt/images/
|
||||||
|
if !config.qemu_use_session
|
||||||
if env[:machine].config.vm.box
|
if env[:machine].config.vm.box
|
||||||
storage_prefix = File.dirname(@domain_volume_path) + '/' # steal
|
storage_prefix = File.dirname(@domain_volume_path) + '/' # steal
|
||||||
else
|
else
|
||||||
@ -137,6 +138,7 @@ module VagrantPlugins
|
|||||||
xml = Nokogiri::XML(storage_pool.xml_desc)
|
xml = Nokogiri::XML(storage_pool.xml_desc)
|
||||||
storage_prefix = xml.xpath('/pool/target/path').inner_text.to_s + '/'
|
storage_prefix = xml.xpath('/pool/target/path').inner_text.to_s + '/'
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
@disks.each do |disk|
|
@disks.each do |disk|
|
||||||
disk[:path] ||= _disk_name(@name, disk)
|
disk[:path] ||= _disk_name(@name, disk)
|
||||||
|
@ -622,6 +622,8 @@ module VagrantPlugins
|
|||||||
@management_network_pci_slot = nil if @management_network_pci_slot == UNSET_VALUE
|
@management_network_pci_slot = nil if @management_network_pci_slot == UNSET_VALUE
|
||||||
@system_uri = 'qemu:///system' if @system_uri == UNSET_VALUE
|
@system_uri = 'qemu:///system' if @system_uri == UNSET_VALUE
|
||||||
|
|
||||||
|
@qemu_use_session = false if @qemu_use_session == UNSET_VALUE
|
||||||
|
|
||||||
# generate a URI if none is supplied
|
# generate a URI if none is supplied
|
||||||
@uri = _generate_uri if @uri == UNSET_VALUE
|
@uri = _generate_uri if @uri == UNSET_VALUE
|
||||||
|
|
||||||
@ -727,7 +729,6 @@ module VagrantPlugins
|
|||||||
@mgmt_attach = true if @mgmt_attach == UNSET_VALUE
|
@mgmt_attach = true if @mgmt_attach == UNSET_VALUE
|
||||||
|
|
||||||
@qemu_args = [] if @qemu_args == UNSET_VALUE
|
@qemu_args = [] if @qemu_args == UNSET_VALUE
|
||||||
@qemu_use_session = false if @qemu_use_session == UNSET_VALUE
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def validate(machine)
|
def validate(machine)
|
||||||
|
Loading…
Reference in New Issue
Block a user