Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
/mobyPublic

Comments

client: add support for overriding minimum API version#52046

Open
thaJeztah wants to merge 1 commit intomoby:masterfrom
thaJeztah:client_min_api_version_override
Open

client: add support for overriding minimum API version#52046
thaJeztah wants to merge 1 commit intomoby:masterfrom
thaJeztah:client_min_api_version_override

Conversation

@thaJeztah
Copy link
Member

@thaJeztahthaJeztah commentedFeb 15, 2026
edited
Loading

This adds options to override the minimum API version considered when performing API-version negotiation. These options allow the client to either downgrade to versions lower than supported (lower than MinAPIVersion), which may result in degraded functionality, or to raise the minimum version to exclude older API versions.

TheWithMinAPIVersion can be used to set the version programmatically. TheWithMinAPIVersionFromEnv allows a user to set the minimum API version at runtime through theDOCKER_MIN_API_VERSION env-var.

TheWithMinAPIVersionFromEnv is more permissive to account for slightly malformed valus in the environment variables; it accepts whitespace, and API versions with a "v" prefix. It also ignores empty values in the environment-variable (which are considered a no-op).

- What I did

- How I did it

- How to verify it

- Human readable description for the release notes

- client: add`WithMinAPIVersion` and`WithMinAPIVersionFromEnv` options to allow overriding the minimum API versions considered for API version negotiation. These options allow the client to either downgrade to versions lower than supported (lower than MinAPIVersion), which may result in degraded functionality, or to raise the minimum version to exclude older API versions.- client: the`FromEnv` option now includes`WithMinAPIVersionFromEnv`, adding support for overriding the minimum API version through a`DOCKER_MIN_API_VERSION` environment variable.

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

@thaJeztahthaJeztah added this to the29.3.0 milestoneFeb 15, 2026
@thaJeztahthaJeztah added area/apiAPI status/2-code-review kind/enhancementEnhancements are not bugs or new features but can improve usability or performance. impact/changelog impact/go-sdkNoteworthy (compatibility changes) in the Go SDK module/client labelsFeb 15, 2026
@thaJeztahthaJeztahforce-pushed theclient_min_api_version_override branch from92ecf5d to24b69e7CompareFebruary 15, 2026 13:16
Comment on lines +153 to +157
// We allow downgrading the client's minimum version to an unsupported lower version.
doc: "downgrade minimum version",
version: "1.0",
expected: "1.0",
},
Copy link
MemberAuthor

Choose a reason for hiding this comment

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

FWIW; we could apply the same limits as are used for the daemon; the daemon also acceptsDOCKER_MIN_API_VERSION as an env-var, but constraints it to1.24 as that was what we already dropped support for (see#51186 and#46887);

// defaultMinAPIVersion is the minimum API version supported by the API.
// This version can be overridden through the "DOCKER_MIN_API_VERSION"
// environment variable. The minimum allowed version is determined
// by [MinAPIVersion].
defaultMinAPIVersion="1.44"
// MinAPIVersion is the minimum API version supported by the daemon.
MinAPIVersion="1.24"

This adds options to override the minimum API version consideredwhen performing API-version negotiation. These options allow theclient to either downgrade to versions lower than supported (lowerthan MinAPIVersion), which may result in degraded functionality,or to raise the minimum version to exclude older API versions.The `WithMinAPIVersion` can be used to set the version programmatically.The `WithMinAPIVersionFromEnv` allows a user to set the minimum APIversion at runtime through the `DOCKER_MIN_API_VERSION` env-var.The `WithMinAPIVersionFromEnv` is more permissive to account forslightly malformed valus in the environment variables; it acceptswhitespace, and API versions with a "v" prefix. It also ignoresempty values in the environment-variable (which are considered ano-op).Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
@thaJeztahthaJeztahforce-pushed theclient_min_api_version_override branch from24b69e7 to4d9a33aCompareFebruary 17, 2026 09:19
@thaJeztah
Copy link
MemberAuthor

On oracle (VM, rootless);

=== Failed=== FAIL: amd64.docker.docker.integration.container TestContainerRestartWithCancelledRequest (3.65s)    restart_test.go:283: timeout waiting for restart event

Windows (graphdriver, builtin);

=== Failed=== FAIL: integration/container TestContainerRestartWithCancelledRequest (77.85s)    restart_test.go:283: timeout waiting for restart event

Windows (graphdriver, containerd);

=== Failed=== FAIL: integration/container TestWaitNonBlocked/wait-nonblocking-exit-0 (33.64s)    wait_test.go:46: timeout hit after 30s: waiting for container State.Status to be 'exited', currently 'running'

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

Reviewers

@vvolandvvolandAwaiting requested review from vvoland

@robmryrobmryAwaiting requested review from robmry

At least 1 approving review is required to merge this pull request.

Assignees

No one assigned

Labels

area/apiAPIimpact/changelogimpact/go-sdkNoteworthy (compatibility changes) in the Go SDKkind/enhancementEnhancements are not bugs or new features but can improve usability or performance.module/clientstatus/2-code-review

Projects

None yet

Milestone

29.3.0

Development

Successfully merging this pull request may close these issues.

1 participant

@thaJeztah

[8]ページ先頭

©2009-2026 Movatter.jp