Attempt to read guest additions version from showvminfo [GH-1575]
This commit is contained in:
parent
efcb25693e
commit
d8ff2cb5ad
|
@ -12,6 +12,8 @@ IMPROVEMENTS:
|
||||||
- Better locking around handling the `box_url` parameter for
|
- Better locking around handling the `box_url` parameter for
|
||||||
parallel providers.
|
parallel providers.
|
||||||
- Solaris guest is now properly detected on SmartOS, OmniOS, etc. [GH-1639]
|
- Solaris guest is now properly detected on SmartOS, OmniOS, etc. [GH-1639]
|
||||||
|
- Guest addition version detection is more robust, attempting other
|
||||||
|
routes to get the version, and also retrying a few times. [GH-1575]
|
||||||
|
|
||||||
BUG FIXES:
|
BUG FIXES:
|
||||||
|
|
||||||
|
|
|
@ -264,6 +264,13 @@ module VagrantPlugins
|
||||||
return value.split("_").first
|
return value.split("_").first
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# If we can't get the guest additions version by guest property, try
|
||||||
|
# to get it from the VM info itself.
|
||||||
|
info = execute("showvminfo", @uuid, "--machinereadable", :retryable => true)
|
||||||
|
info.split("\n").each do |line|
|
||||||
|
return $1.to_s if line =~ /^GuestAdditionsVersion="(.+?)"$/
|
||||||
|
end
|
||||||
|
|
||||||
return nil
|
return nil
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue