Skip to content

Commit 1dee910

Browse files
authored
Merge pull request docker#93 from doringeman/api-version-negotiation
Enable automatic API version negotiation for the Docker client
2 parents 651163c + 1ef568d commit 1dee910

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

cmd/cli/desktop/context.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,11 @@ func DockerClientForContext(cli *command.DockerCli, name string) (*clientpkg.Cli
7272
if err != nil {
7373
return nil, fmt.Errorf("unable to determine context endpoint: %w", err)
7474
}
75-
return clientpkg.NewClientWithOpts(clientpkg.FromEnv, clientpkg.WithHost(endpoint.Host))
75+
return clientpkg.NewClientWithOpts(
76+
clientpkg.FromEnv,
77+
clientpkg.WithHost(endpoint.Host),
78+
clientpkg.WithAPIVersionNegotiation(),
79+
)
7680
}
7781

7882
// ModelRunnerEngineKind encodes the kind of Docker engine associated with the

0 commit comments

Comments
 (0)