Added the paths suggested by @phekmat and @SwampDragons for VMware Fusion... Although parser for the new mapper format is likely to be needed still.
This commit is contained in:
parent
8cc0776f3a
commit
069d00f70b
|
@ -141,10 +141,21 @@ func (d *Fusion5Driver) Verify() error {
|
|||
return err
|
||||
}
|
||||
|
||||
// default paths
|
||||
libpath := filepath.Join("Library", "Preferences", "VMware Fusion")
|
||||
|
||||
d.VmwareDriver.DhcpLeasesPath = func(device string) string {
|
||||
return "/var/db/vmware/vmnet-dhcpd-" + device + ".leases"
|
||||
}
|
||||
d.VmwareDriver.DhcpConfPath = func(device string) string {
|
||||
return filepath.Join(libpath, device, "dhcpd.conf")
|
||||
}
|
||||
d.VmwareDriver.VmnetnatConfPath = func(device string) string {
|
||||
return filepath.Join(libpath, device, "nat.conf")
|
||||
}
|
||||
d.VmwareDriver.NetmapConfPath = func() string {
|
||||
// FIXME: Suggested by @phekmat. This will need another parser to be implemented.
|
||||
return filepath.Join(libpath, "networking")
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
|
|
@ -66,6 +66,23 @@ func (d *Fusion6Driver) Verify() error {
|
|||
}
|
||||
log.Printf("Detected VMware version: %s", matches[1])
|
||||
|
||||
libpath := filepath.Join("Library", "Preferences", "VMware Fusion")
|
||||
|
||||
d.VmwareDriver.DhcpLeasesPath = func(device string) string {
|
||||
return "/var/db/vmware/vmnet-dhcpd-" + device + ".leases"
|
||||
}
|
||||
d.VmwareDriver.DhcpConfPath = func(device string) string {
|
||||
return filepath.Join(libpath, device, "dhcpd.conf")
|
||||
}
|
||||
|
||||
d.VmwareDriver.VmnetnatConfPath = func(device string) string {
|
||||
return filepath.Join(libpath, device, "nat.conf")
|
||||
}
|
||||
d.VmwareDriver.NetmapConfPath = func() string {
|
||||
// FIXME: Suggested by @phekmat. This will need another parser to be implemented.
|
||||
return filepath.Join(libpath, "networking")
|
||||
}
|
||||
|
||||
return compareVersions(matches[1], VMWARE_FUSION_VERSION, "Fusion Professional")
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue