DockerCLI/cli/command
Sebastiaan van Stijn 258e27438f
context list: temporarily add ContextType to JSON output
Docker Desktop currently ships with the "cloud integration" wrapper,
which outputs an additional ContextType field in the JSON output.

While this field is non-standard, it made its way into Visual Studio's
Docker integration, which uses this to exclude "aci" and "eci" context
types that are not supported by Visual Studio.

This patch;

- conditionally adds a ContextType field to the JSON output
- but ONLY when using the default "{{json .}}" or "json" formats
  (which are the formats used by Visual Studio)
- if the context is a "aci" or "eci" context, that type is
  preserved, otherwise the default "moby" type is used.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit fed9fa0f72)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2024-05-31 14:48:35 +02:00
..
builder chore: remove backticks and resolve linting issues 2024-04-02 15:54:29 +02:00
checkpoint cli/command: don't use pflags.XXXVarP for flags without shorthand 2024-01-29 11:16:38 +01:00
commands remove exec, push, pull, ps, images, info from "legacy" commands 2022-04-08 16:55:39 +02:00
completion Replace deprecated types.Image* usage 2024-01-24 14:59:10 +01:00
config cli/command: don't use pflags.XXXVarP for flags without shorthand 2024-01-29 11:16:38 +01:00
container Fix hang when container fails to start 2024-05-07 11:57:24 +01:00
context context list: temporarily add ContextType to JSON output 2024-05-31 14:48:35 +02:00
formatter context list: temporarily add ContextType to JSON output 2024-05-31 14:48:35 +02:00
idresolver add //go:build directives to prevent downgrading to go1.16 language 2023-12-14 15:03:46 +01:00
image chore: remove backticks and resolve linting issues 2024-04-02 15:54:29 +02:00
inspect add //go:build directives to prevent downgrading to go1.16 language 2023-12-14 15:03:46 +01:00
manifest Plumb contexts through commands 2023-12-12 22:30:16 +01:00
network chore: remove backticks and resolve linting issues 2024-04-02 15:54:29 +02:00
node add //go:build directives to prevent downgrading to go1.16 language 2023-12-14 15:03:46 +01:00
plugin chore: remove backticks and resolve linting issues 2024-04-02 15:54:29 +02:00
registry cli/command: don't use pflags.XXXVarP for flags without shorthand 2024-01-29 11:16:38 +01:00
secret cli/command: don't use pflags.XXXVarP for flags without shorthand 2024-01-29 11:16:38 +01:00
service Add support for --detach flag in stack deploy 2024-03-04 09:36:36 +01:00
stack Add support for --detach/-d flag in stack rm 2024-03-04 09:56:53 +01:00
swarm cli/command: don't use pflags.XXXVarP for flags without shorthand 2024-01-29 11:16:38 +01:00
system chore: remove backticks and resolve linting issues 2024-04-02 15:54:29 +02:00
task linting: address slice-append issues found by gocritic 2023-11-20 16:02:17 +01:00
testdata Dynamically register kubernetes context store endpoint type. 2019-05-20 13:28:11 +01:00
trust chore: remove backticks and resolve linting issues 2024-04-02 15:54:29 +02:00
volume chore: remove backticks and resolve linting issues 2024-04-02 15:54:29 +02:00
cli.go Use funcs on DockerCli to return Meter/TracerProviders, not initialize them. Initialize them during DockerCli struct init 2024-05-14 16:31:06 +01:00
cli_options.go cli/command: remove deprecated DockerCliOption, InitializeOpt 2024-01-20 21:39:32 +01:00
cli_options_test.go golangci-lint: enable thelper linter 2023-11-20 16:02:17 +01:00
cli_test.go cli-plugins: Introduce support for hooks 2024-03-22 17:30:18 +00:00
context.go add //go:build directives to prevent downgrading to go1.16 language 2023-12-14 15:03:46 +01:00
context_test.go add //go:build directives to prevent downgrading to go1.16 language 2023-12-14 15:03:46 +01:00
defaultcontextstore.go add //go:build directives to prevent downgrading to go1.16 language 2023-12-14 15:03:46 +01:00
defaultcontextstore_test.go add //go:build directives to prevent downgrading to go1.16 language 2023-12-14 15:03:46 +01:00
events_utils.go cli/command: deprecate EventHandler and InitEventHandler 2024-03-11 13:25:22 +01:00
registry.go migrate reference github.com/distribution/reference 2023-09-05 17:53:20 +02:00
registry_test.go cli/command: remove dot-imports and unhandled errors 2023-10-23 15:21:47 +02:00
telemetry.go OTel: implement missing MeterProvider `ForceFlush` 2024-05-15 02:00:06 +01:00
telemetry_docker.go Fix OTLP env var overriding 2024-04-17 14:32:41 +00:00
telemetry_utils.go OTel: add `command.time` metric to plugin commands 2024-05-15 02:00:05 +01:00
telemetry_utils_test.go otel: capture exit code as int64 2024-04-04 19:11:56 +01:00
trust.go Refactor content_trust cli/flags handling 2018-03-08 15:00:43 -05:00
utils.go chore: remove backticks and resolve linting issues 2024-04-02 15:54:29 +02:00
utils_test.go refactor: prompt tests 2024-03-26 10:07:01 +01:00