mirror of https://github.com/docker/cli.git
login: normalize `registry-1.docker.io`
Signed-off-by: Laura Brehm <laurabrehm@hey.com>
(cherry picked from commit e6624676e0
)
Signed-off-by: Laura Brehm <laurabrehm@hey.com>
This commit is contained in:
parent
b8a38fd22d
commit
afb5e143b1
|
@ -109,7 +109,9 @@ func runLogin(ctx context.Context, dockerCli command.Cli, opts loginOptions) err
|
|||
serverAddress string
|
||||
response *registrytypes.AuthenticateOKBody
|
||||
)
|
||||
if opts.serverAddress != "" && opts.serverAddress != registry.DefaultNamespace {
|
||||
if opts.serverAddress != "" &&
|
||||
opts.serverAddress != registry.DefaultNamespace &&
|
||||
opts.serverAddress != registry.DefaultRegistryHost {
|
||||
serverAddress = opts.serverAddress
|
||||
} else {
|
||||
serverAddress = registry.IndexServer
|
||||
|
|
Loading…
Reference in New Issue