Windows: Fix docker login

Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 9c765040a5638429384b56a1b77139c6d4049c75
Component: engine
This commit is contained in:
John Howard
2015-11-05 14:19:48 -08:00
parent 7928e48119
commit d0707f6b8c

View File

@ -6,6 +6,7 @@ import (
"fmt"
"io"
"os"
"runtime"
"strings"
"github.com/docker/docker/api/types"
@ -33,6 +34,11 @@ func (cli *DockerCli) CmdLogin(args ...string) error {
cmd.ParseFlags(args, true)
// On Windows, force the use of the regular OS stdin stream. Fixes #14336/#14210
if runtime.GOOS == "windows" {
cli.in = os.Stdin
}
serverAddress := registry.IndexServer
if len(cmd.Args()) > 0 {
serverAddress = cmd.Arg(0)