From c4fdb56e903093fe9f7ca80512b41f852957f970 Mon Sep 17 00:00:00 2001 From: Joao Carlos Date: Tue, 31 Jul 2018 00:15:16 +0300 Subject: [PATCH] Update docker/machine dependencies Fixes an issue that prevents the vmwarefusion driver from working with minikube. --- Godeps/Godeps.json | 130 +++++++++--------- .../docker/machine/drivers/hyperv/hyperv.go | 44 ++++-- .../drivers/vmwarefusion/fusion_darwin.go | 4 +- .../docker/machine/libmachine/ssh/client.go | 9 +- 4 files changed, 102 insertions(+), 85 deletions(-) diff --git a/Godeps/Godeps.json b/Godeps/Godeps.json index f3dcd1e50d9e..3992b557cce9 100644 --- a/Godeps/Godeps.json +++ b/Godeps/Godeps.json @@ -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", diff --git a/vendor/github.com/docker/machine/drivers/hyperv/hyperv.go b/vendor/github.com/docker/machine/drivers/hyperv/hyperv.go index cf86801d435e..6740f295e469 100644 --- a/vendor/github.com/docker/machine/drivers/hyperv/hyperv.go +++ b/vendor/github.com/docker/machine/drivers/hyperv/hyperv.go @@ -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", diff --git a/vendor/github.com/docker/machine/drivers/vmwarefusion/fusion_darwin.go b/vendor/github.com/docker/machine/drivers/vmwarefusion/fusion_darwin.go index 74a2cc510efc..1211304e31e5 100644 --- a/vendor/github.com/docker/machine/drivers/vmwarefusion/fusion_darwin.go +++ b/vendor/github.com/docker/machine/drivers/vmwarefusion/fusion_darwin.go @@ -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) } } diff --git a/vendor/github.com/docker/machine/libmachine/ssh/client.go b/vendor/github.com/docker/machine/libmachine/ssh/client.go index abd4705dfbca..afba46dedf81 100644 --- a/vendor/github.com/docker/machine/libmachine/ssh/client.go +++ b/vendor/github.com/docker/machine/libmachine/ssh/client.go @@ -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 )