docker info: don't print "registry" (IndexServerAddress)

The IndexServerAddress field was  as part of the initial Windows implementation
of the engine. For legal reasons, Microsoft Windows (and thus Docker images
based on Windows) were not allowed to be distributed through non-Microsoft
infrastructure. As a temporary solution, a dedicated "registry-win-tp3.docker.io"
registry was created to serve Windows images.

Currently, this field always shows "https://index.docker.io/v1/", which is
confusing, because that address is not used for the registry (only for
authentication and "v1" search).

    docker info
    ...
    Registry: https://index.docker.io/v1/

Starting with b4ca1c7368, this field is also
no longer used during authentication, and a3d56e7d06
removed the (deprecated) ElectAuthServer() which was previously used to
query it.

Given that there's currently no practical use for this information, and
it only adds "noise" (and confusion), this patch removes it from the default
output.

For now, the field is (still) available for those that want to use it;

    docker info --format '{{.IndexServerAddress}}'
    https://index.docker.io/v1/

But it won't be printed by default.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn 2023-04-13 14:49:14 +02:00
parent c25115e968
commit 375b17a312
No known key found for this signature in database
GPG Key ID: 76698F39D527CE8C
9 changed files with 0 additions and 10 deletions

View File

@ -324,7 +324,6 @@ func prettyPrintServerInfo(dockerCli command.Cli, info types.Info) []error {
if len(u) > 0 {
fmt.Fprintln(dockerCli.Out(), " Username:", u)
}
fmt.Fprintln(dockerCli.Out(), " Registry:", info.IndexServerAddress)
}
if len(info.Labels) > 0 {

View File

@ -41,7 +41,6 @@ Server:
Goroutines: 135
System Time: 2017-08-24T17:44:34.077811894Z
EventsListeners: 0
Registry: https://index.docker.io/v1/
Labels:
provider=digitalocean
Experimental: false

View File

@ -46,7 +46,6 @@ Server:
Goroutines: 135
System Time: 2017-08-24T17:44:34.077811894Z
EventsListeners: 0
Registry: https://index.docker.io/v1/
Labels:
provider=digitalocean
Experimental: false

View File

@ -51,7 +51,6 @@ Server:
Goroutines: 135
System Time: 2017-08-24T17:44:34.077811894Z
EventsListeners: 0
Registry: https://index.docker.io/v1/
Labels:
provider=digitalocean
Experimental: false

View File

@ -45,7 +45,6 @@ Server:
Goroutines: 135
System Time: 2017-08-24T17:44:34.077811894Z
EventsListeners: 0
Registry: https://index.docker.io/v1/
Experimental: false
Insecure Registries:
127.0.0.0/8

View File

@ -45,7 +45,6 @@ Server:
Goroutines: 135
System Time: 2017-08-24T17:44:34.077811894Z
EventsListeners: 0
Registry: https://index.docker.io/v1/
Experimental: false
Insecure Registries:
127.0.0.0/8

View File

@ -67,7 +67,6 @@ Server:
Goroutines: 135
System Time: 2017-08-24T17:44:34.077811894Z
EventsListeners: 0
Registry: https://index.docker.io/v1/
Labels:
provider=digitalocean
Experimental: false

View File

@ -102,7 +102,6 @@ Server:
Docker Root Dir: /var/lib/docker
Debug Mode: false
Username: gordontheturtle
Registry: https://index.docker.io/v1/
Experimental: false
Insecure Registries:
myinsecurehost:5000
@ -164,7 +163,6 @@ Server:
ID: 2880d38d-464e-4d01-91bd-c76f33ba3981
Docker Root Dir: C:\ProgramData\docker
Debug Mode: false
Registry: https://index.docker.io/v1/
Experimental: true
Insecure Registries:
myregistry:5000

View File

@ -82,7 +82,6 @@ Server:
Docker Root Dir: /var/lib/docker
Debug Mode: false
Username: gordontheturtle
Registry: https://index.docker.io/v1/
Experimental: false
Insecure Registries:
myinsecurehost:5000