Update docker/machine dependencies
Fixes an issue that prevents the vmwarefusion driver from working with minikube.pull/2668/merge
parent
f8c16a7bbb
commit
74d6155d47
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"ImportPath": "k8s.io/minikube",
|
||||
"GoVersion": "go1.10",
|
||||
"GodepVersion": "v79",
|
||||
"GodepVersion": "v80",
|
||||
"Packages": [
|
||||
"./..."
|
||||
],
|
||||
|
@ -50,163 +50,163 @@
|
|||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/commands/mcndirs",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/drivers/errdriver",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/drivers/hyperv",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/drivers/none",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/drivers/virtualbox",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/drivers/vmwarefusion",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/auth",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/cert",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/check",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/drivers",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/drivers/plugin",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/drivers/plugin/localbinary",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/drivers/rpc",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/engine",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/host",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/log",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/mcndockerclient",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/mcnerror",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/mcnflag",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/mcnutils",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/persist",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/provision",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/provision/pkgaction",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/provision/serviceaction",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/shell",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/ssh",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/state",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/swarm",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/version",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/libmachine/versioncmp",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/docker/machine/version",
|
||||
"Comment": "docs-v0.8.2-2016-09-26-373-g1e3b6b64",
|
||||
"Rev": "1e3b6b64504f2970252b06119d6dc1fb1982b4b4"
|
||||
"Comment": "docs-v0.8.2-2016-09-26-391-g1903531",
|
||||
"Rev": "19035310d4ba1b58056aae427ea669d1db5fc618"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/fsnotify/fsnotify",
|
||||
|
|
|
@ -16,28 +16,31 @@ import (
|
|||
|
||||
type Driver struct {
|
||||
*drivers.BaseDriver
|
||||
Boot2DockerURL string
|
||||
VSwitch string
|
||||
DiskSize int
|
||||
MemSize int
|
||||
CPU int
|
||||
MacAddr string
|
||||
VLanID int
|
||||
Boot2DockerURL string
|
||||
VSwitch string
|
||||
DiskSize int
|
||||
MemSize int
|
||||
CPU int
|
||||
MacAddr string
|
||||
VLanID int
|
||||
DisableDynamicMemory bool
|
||||
}
|
||||
|
||||
const (
|
||||
defaultDiskSize = 20000
|
||||
defaultMemory = 1024
|
||||
defaultCPU = 1
|
||||
defaultVLanID = 0
|
||||
defaultDiskSize = 20000
|
||||
defaultMemory = 1024
|
||||
defaultCPU = 1
|
||||
defaultVLanID = 0
|
||||
defaultDisableDynamicMemory = false
|
||||
)
|
||||
|
||||
// NewDriver creates a new Hyper-v driver with default settings.
|
||||
func NewDriver(hostName, storePath string) *Driver {
|
||||
return &Driver{
|
||||
DiskSize: defaultDiskSize,
|
||||
MemSize: defaultMemory,
|
||||
CPU: defaultCPU,
|
||||
DiskSize: defaultDiskSize,
|
||||
MemSize: defaultMemory,
|
||||
CPU: defaultCPU,
|
||||
DisableDynamicMemory: defaultDisableDynamicMemory,
|
||||
BaseDriver: &drivers.BaseDriver{
|
||||
MachineName: hostName,
|
||||
StorePath: storePath,
|
||||
|
@ -88,6 +91,11 @@ func (d *Driver) GetCreateFlags() []mcnflag.Flag {
|
|||
Value: defaultVLanID,
|
||||
EnvVar: "HYPERV_VLAN_ID",
|
||||
},
|
||||
mcnflag.BoolFlag{
|
||||
Name: "hyperv-disable-dynamic-memory",
|
||||
Usage: "Disable dynamic memory management setting",
|
||||
EnvVar: "HYPERV_DISABLE_DYNAMIC_MEMORY",
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -100,6 +108,7 @@ func (d *Driver) SetConfigFromFlags(flags drivers.DriverOptions) error {
|
|||
d.MacAddr = flags.String("hyperv-static-macaddress")
|
||||
d.VLanID = flags.Int("hyperv-vlan-id")
|
||||
d.SSHUser = "docker"
|
||||
d.DisableDynamicMemory = flags.Bool("hyperv-disable-dynamic-memory")
|
||||
d.SetSwarmConfigFromFlags(flags)
|
||||
|
||||
return nil
|
||||
|
@ -212,6 +221,13 @@ func (d *Driver) Create() error {
|
|||
"-MemoryStartupBytes", toMb(d.MemSize)); err != nil {
|
||||
return err
|
||||
}
|
||||
if d.DisableDynamicMemory {
|
||||
if err := cmd("Hyper-V\\Set-VMMemory",
|
||||
"-VMName", d.MachineName,
|
||||
"-DynamicMemoryEnabled", "$false"); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
if d.CPU > 1 {
|
||||
if err := cmd("Hyper-V\\Set-VMProcessor",
|
||||
|
|
|
@ -403,7 +403,7 @@ func (d *Driver) Create() error {
|
|||
if err != nil {
|
||||
return err
|
||||
}
|
||||
command := "[ ! -d " + shareDir + " ]&& sudo mkdir " + shareDir + "; sudo mount --bind /mnt/hgfs/" + shareDir + " " + shareDir + " || [ -f /usr/local/bin/vmhgfs-fuse ]&& sudo /usr/local/bin/vmhgfs-fuse -o allow_other .host:/" + shareName + " " + shareDir + " || sudo mount -t vmhgfs -o uid=$(id -u),gid=$(id -g) .host:/" + shareName + " " + shareDir
|
||||
command := "([ ! -d " + shareDir + " ]&& sudo mkdir " + shareDir + "; sudo mount --bind /mnt/hgfs/" + shareDir + " " + shareDir + ") || ([ -f /usr/local/bin/vmhgfs-fuse ]&& sudo /usr/local/bin/vmhgfs-fuse -o allow_other .host:/" + shareName + " " + shareDir + ") || sudo mount -t vmhgfs -o uid=$(id -u),gid=$(id -g) .host:/" + shareName + " " + shareDir
|
||||
_, _, err = vmrun("-gu", B2DUser, "-gp", B2DPass, "runScriptInGuest", d.vmxPath(), "/bin/sh", command)
|
||||
if err != nil {
|
||||
return err
|
||||
|
@ -436,7 +436,7 @@ func (d *Driver) Start() error {
|
|||
return err
|
||||
} else if !os.IsNotExist(err) {
|
||||
// create mountpoint and mount shared folder
|
||||
command := "[ ! -d " + shareDir + " ]&& sudo mkdir " + shareDir + "; sudo mount --bind /mnt/hgfs/" + shareDir + " " + shareDir + " || [ -f /usr/local/bin/vmhgfs-fuse ]&& sudo /usr/local/bin/vmhgfs-fuse -o allow_other .host:/" + shareName + " " + shareDir + " || sudo mount -t vmhgfs -o uid=$(id -u),gid=$(id -g) .host:/" + shareName + " " + shareDir
|
||||
command := "([ ! -d " + shareDir + " ]&& sudo mkdir " + shareDir + "; sudo mount --bind /mnt/hgfs/" + shareDir + " " + shareDir + ") || ([ -f /usr/local/bin/vmhgfs-fuse ]&& sudo /usr/local/bin/vmhgfs-fuse -o allow_other .host:/" + shareName + " " + shareDir + ") || sudo mount -t vmhgfs -o uid=$(id -u),gid=$(id -g) .host:/" + shareName + " " + shareDir
|
||||
vmrun("-gu", B2DUser, "-gp", B2DPass, "runScriptInGuest", d.vmxPath(), "/bin/sh", command)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -68,14 +68,15 @@ const (
|
|||
var (
|
||||
baseSSHArgs = []string{
|
||||
"-F", "/dev/null",
|
||||
"-o", "PasswordAuthentication=no",
|
||||
"-o", "StrictHostKeyChecking=no",
|
||||
"-o", "UserKnownHostsFile=/dev/null",
|
||||
"-o", "LogLevel=quiet", // suppress "Warning: Permanently added '[localhost]:2022' (ECDSA) to the list of known hosts."
|
||||
"-o", "ConnectionAttempts=3", // retry 3 times if SSH connection fails
|
||||
"-o", "ConnectTimeout=10", // timeout after 10 seconds
|
||||
"-o", "ControlMaster=no", // disable ssh multiplexing
|
||||
"-o", "ControlPath=none",
|
||||
"-o", "LogLevel=quiet", // suppress "Warning: Permanently added '[localhost]:2022' (ECDSA) to the list of known hosts."
|
||||
"-o", "PasswordAuthentication=no",
|
||||
"-o", "ServerAliveInterval=60", // prevents connection to be dropped if command takes too long
|
||||
"-o", "StrictHostKeyChecking=no",
|
||||
"-o", "UserKnownHostsFile=/dev/null",
|
||||
}
|
||||
defaultClientType = External
|
||||
)
|
||||
|
|
Loading…
Reference in New Issue