未验证 提交 cf11d47f 编写于 作者: T Thomas Strömberg 提交者: GitHub

Merge pull request #7090 from tstromberg/docker-default

Upgrade Docker driver to preferred (Linux), default on other platforms
......@@ -20,6 +20,7 @@ import (
"context"
"fmt"
"os/exec"
"runtime"
"time"
"github.com/docker/machine/libmachine/drivers"
......@@ -32,12 +33,21 @@ import (
)
func init() {
priority := registry.Default
// Staged rollout for preferred:
// - Linux
// - Windows (once "service" command works)
// - macOS
if runtime.GOOS == "linux" {
priority = registry.Preferred
}
if err := registry.Register(registry.DriverDef{
Name: driver.Docker,
Config: configure,
Init: func() drivers.Driver { return kic.NewDriver(kic.Config{OCIBinary: oci.Docker}) },
Status: status,
Priority: registry.Fallback,
Priority: priority,
}); err != nil {
panic(fmt.Sprintf("register failed: %v", err))
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册