[28.x backport] Add escape hatch for GODEBUG=x509negativeserial by vvoland · Pull Request #6399 · docker/cli · GitHub
Skip to content

[28.x backport] Add escape hatch for GODEBUG=x509negativeserial - #6399

Merged
vvoland merged 5 commits into
docker:28.xfrom
vvoland:6371-28.x
Aug 29, 2025
Merged

vvoland merged 5 commits into
docker:28.xfrom
vvoland:6371-28.x

Conversation

@vvoland

@vvoland vvoland commented Aug 29, 2025

Copy link
Copy Markdown
Collaborator

- What I did
Negative serial number certificates are deprecated and Go has also since deprecated them. To use them with Go you need to pass in the GODEBUG=x509negativeserial=1 environment variable.

This PR allows setting the value inside docker context instead. This should then propagate environment variables to underlying plugins (such as buildx).

{
  "Name": "my-context",
  "Metadata": { "GODEBUG": "x509negativeserial=1" },
  "Endpoints": {
    "docker": { "Host": "unix:///var/run/docker.sock", "SkipTLSVerify": false }
  }
}

- How I did it

- How to verify it

- Human readable description for the release notes

Allow Docker CLI to set the `GODEBUG` environment variable when the key-value pair (`"GODEBUG":"..."`) exists inside the docker context metadata.

- A picture of a cute animal (not mandatory but encouraged)

Signed-off-by: Alano Terblanche <18033717+Benehiko@users.noreply.github.com>
(cherry picked from commit 7d7a7aa)
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
Signed-off-by: Alano Terblanche <18033717+Benehiko@users.noreply.github.com>
(cherry picked from commit 65a6c35)
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
Signed-off-by: Alano Terblanche <18033717+Benehiko@users.noreply.github.com>
(cherry picked from commit 467305f)
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
Signed-off-by: Alano Terblanche <18033717+Benehiko@users.noreply.github.com>
(cherry picked from commit 6163c03)
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
Signed-off-by: Alano Terblanche <18033717+Benehiko@users.noreply.github.com>
(cherry picked from commit 72f7933)
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
@codecov-commenter

Copy link
Copy Markdown

@thaJeztah thaJeztah left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

sorry, looks like I missed that it could've used some squashing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants