8000 api/types/registry: update deprecation comment for AuthConfig.Email · moby/moby@6cfff7e · GitHub
[go: up one dir, main page]

Skip to content

Commit 6cfff7e

Browse files
committed
api/types/registry: update deprecation comment for AuthConfig.Email
The Email field was originally used to create a new Docker Hub account through the `docker login` command. The `docker login` command could be used both to log in to an existing account (providing only username and password), or to create a new account (providing desired username and password, and an e-mail address to use for the new account). This functionality was confusing, because it was implemented when Docker Hub was the only registry, but the same functionality could not be used for other registries. This functionality was removed in Docker 1.11 (API version 1.23) through [aee260d], which also removed the Email field ([engine-api@9a9e468]) as it was no longer used. However, this caused issues when using a new CLI connecting with an old daemon, as the field would no longer be serialized, and the deprecation may not yet be picked up by custom registries, so [engine-api@167efc7] added the field back, deprecated it, and added an "omitempty". There was no official "deprecated" format yet at the time, so let's make sure the deprecation follows the proper format to make sure it gets noticed. [aee260d]: aee260d [engine-api@9a9e468]: docker-archive-public/docker.engine-api@9a9e468 [engine-api@167efc7]: docker-archive-public/docker.engine-api@167efc7 Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
1 parent 7d65b67 commit 6cfff7e

File tree

4 files changed

+12
-4
lines changed

4 files changed

+12
-4
lines changed

api/swagger.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2246,6 +2246,10 @@ definitions:
22462246
password:
22472247
type: "string"
22482248
email:
2249+
description: |
2250+
Email is an optional value associated with the username.
2251+
2252+
> **Deprecated**: This field is deprecated since docker 1.11 (API v1.23) and will be removed in a future release.
22492253
type: "string"
22502254
serveraddress:
22512255
type: "string"

api/types/registry/authconfig.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ type AuthConfig struct {
3333
Auth string `json:"auth,omitempty"`
3434

3535
// Email is an optional value associated with the username.
36-
// This field is deprecated and will be removed in a later
37-
// version of docker.
36+
//
37+
// Deprecated: This field is deprecated since docker 1.11 (API v1.23) and will be removed in the next release.
3838
Email string `json:"email,omitempty"`
3939

4040
ServerAddress string `json:"serveraddress,omitempty"`

vendor/github.com/moby/moby/api/swagger.yaml

Lines changed: 4 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/moby/moby/api/types/registry/authconfig.go

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)
0