DockerCLI/cmd/docker
Sebastiaan van Stijn 006c946389
cmd/docker: make feature detection lazy again
Commit 20ba591b7f fixed incorrect feature
detection in the CLI, but introduced a regression; previously the "ping"
would only be executed if needed (see b39739123b),
but by not inlining the call to `ServerInfo()` would now always be called.

This patch inlines the code again to only execute the "ping" conditionally,
which allows it to be executed lazily (and omitted for commands that don't
require a daemon connection).

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2022-12-06 10:17:50 +01:00
..
winresources Use goversioninfo to create Windows Version Info 2021-10-11 16:54:22 +02:00
aliases.go build: set default context builder if not specified 2022-11-04 08:42:34 +01:00
builder.go build: keep "buildx install" behavior 2022-11-04 08:42:34 +01:00
builder_test.go cil/command: use dummy client for build-tests 2022-12-05 22:37:40 +01:00
builder_windows_test.go build: set default context builder if not specified 2022-11-04 08:42:34 +01:00
completions.go Adopt Cobra completion v2 to support completion by CLI plugins 2022-05-12 12:59:10 +02:00
docker.go cmd/docker: make feature detection lazy again 2022-12-06 10:17:50 +01:00
docker_test.go Adopt Cobra completion v2 to support completion by CLI plugins 2022-05-12 12:59:10 +02:00
docker_windows_386.go Use goversioninfo to create Windows Version Info 2021-10-11 16:54:22 +02:00
docker_windows_amd64.go Use goversioninfo to create Windows Version Info 2021-10-11 16:54:22 +02:00
docker_windows_arm.go Use goversioninfo to create Windows Version Info 2021-10-11 16:54:22 +02:00
docker_windows_arm64.go Use goversioninfo to create Windows Version Info 2021-10-11 16:54:22 +02:00