Skip to content
This repository has been archived by the owner on Nov 27, 2023. It is now read-only.

Docker login to local server fails with "unknown backend type for cloud login" #712

Closed
hmottestad opened this issue Sep 23, 2020 · 8 comments
Assignees

Comments

@hmottestad
Copy link

Description

After upgrading to Docker Desktop community 2.3.0.5 the docker login command fails with unknown backend when provided with a minimal domain name.

Steps to reproduce the issue:

  1. docker login localhost:443

Describe the results you received:
unknown backend type for cloud login: localhost:443

Describe the results you expected:
Same as when using (with . at end of domain name): docker login localhost.:443

Additional information you deem important (e.g. issue happens only occasionally):

Should also work for local domains. In our case our docker registry is running on https://docker-registry:443.

Output of docker version:

Client: Docker Engine - Community
 Azure integration  0.1.15
 Version:           19.03.12
 API version:       1.40
 Go version:        go1.13.10
 Git commit:        48a66213fe
 Built:             Mon Jun 22 15:41:33 2020
 OS/Arch:           darwin/amd64
 Experimental:      false

Server: Docker Engine - Community
 Engine:
  Version:          19.03.12
  API version:      1.40 (minimum version 1.12)
  Go version:       go1.13.10
  Git commit:       48a66213fe
  Built:            Mon Jun 22 15:49:27 2020
  OS/Arch:          linux/amd64
  Experimental:     false
 containerd:
  Version:          v1.2.13
  GitCommit:        7ad184331fa3e55e52b890ea95e65ba581ae3429
 runc:
  Version:          1.0.0-rc10
  GitCommit:        dc9208a3303feef5b3839f4323d9beb36df0a9dd
 docker-init:
  Version:          0.18.0
  GitCommit:        fec3683

Output of docker info:

Client:
 Debug Mode: false

Server:
 Containers: 5
  Running: 5
  Paused: 0
  Stopped: 0
 Images: 1475
 Server Version: 19.03.12
 Storage Driver: overlay2
  Backing Filesystem: extfs
  Supports d_type: true
  Native Overlay Diff: true
 Logging Driver: json-file
 Cgroup Driver: cgroupfs
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
 Swarm: inactive
 Runtimes: runc
 Default Runtime: runc
 Init Binary: docker-init
 containerd version: 7ad184331fa3e55e52b890ea95e65ba581ae3429
 runc version: dc9208a3303feef5b3839f4323d9beb36df0a9dd
 init version: fec3683
 Security Options:
  seccomp
   Profile: default
 Kernel Version: 4.19.76-linuxkit
 Operating System: Docker Desktop
 OSType: linux
 Architecture: x86_64
 CPUs: 4
 Total Memory: 7.78GiB
 Name: docker-desktop
 ID: 7Q62:UF3G:QNWB:WCGN:SW6X:PQLH:TAE3:PI7I:3MXA:4Y5P:G4W7:3IHT
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 HTTP Proxy: gateway.docker.internal:3128
 HTTPS Proxy: gateway.docker.internal:3129
 Registry: https://index.docker.io/v1/
 Labels:
 Experimental: false
 Insecure Registries:
  docker-registry.eos
  docker-registry:443
  127.0.0.0/8
 Live Restore Enabled: false
 Product License: Community Engine

Additional environment details (AWS, VirtualBox, physical, etc.):

@itkg-ppottie
Copy link

itkg-ppottie commented Sep 23, 2020

when you read help , you can understand why:

 docker login --help
Log in to a Docker registry or cloud backend.
If no registry server is specified, the default is defined by the daemon.

Usage:
  docker login [OPTIONS] [SERVER] [flags]
  docker login [command]

Available Commands:
  azure       Log in to azure

So localhost is interpreted like "command" so like a login into azure . insane indeed
you can define an another host name in your /etc/hosts with dot in name like

127.0.0.1 localhost registry.local

@RedHawker
Copy link

It seems like Docker Desktop 2.3.0.5 introduced this bug, reverting to 2.3.0.4 is the current workaround as far as I can tell.

It broke docker login to existing private repositories, which is a regression.

@hmottestad
Copy link
Author

It seems like Docker Desktop 2.3.0.5 introduced this bug, reverting to 2.3.0.4 is the current workaround as far as I can tell.

It broke docker login to existing private repositories, which is a regression.

Another workaround is to append your domain name with a dot.

Eg. localhost -> localhost.

@thaJeztah
Copy link
Member

Sounds like this may be an issue in the command-line used for cloud integration; does the problem go away if you disable the "enable cloud experience" option in the Docker Desktop preferences (under preferences -> command line);

(actually, it may have moved, so perhaps it's named different, so let me know if you can't find the option)

Screenshot 2020-10-02 at 10 42 30

@justincormack
Copy link
Contributor

Apologies for that we will get a fix out ASAP, please use one of the workarounds above for now.

@thaJeztah thaJeztah transferred this issue from docker/cli Oct 2, 2020
@thaJeztah
Copy link
Member

I moved this ticket to the compose-cli repository, which is where the bug looks to be in 👍

@maartenvanderhoef
Copy link

It seems like Docker Desktop 2.3.0.5 introduced this bug, reverting to 2.3.0.4 is the current workaround as far as I can tell.
It broke docker login to existing private repositories, which is a regression.

Another workaround is to append your domain name with a dot.

Eg. localhost -> localhost.

didn't work for me

docker login 127.0.0.1:port did the trick.

@gtardif
Copy link
Contributor

gtardif commented Nov 20, 2020

This has been fixed and shipped in Desktop, feel free to re-opened if you encounter this issue with the latest Desktop version (Edge or stable)

@gtardif gtardif closed this as completed Nov 20, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants