buildx icon indicating copy to clipboard operation
buildx copied to clipboard

docker api: use helper to parse context docker endpoint metadata

Open crazy-max opened this issue 3 years ago • 1 comments

follow-up https://github.com/docker/buildx/issues/1249#issuecomment-1205162020

Use docker.EndpointFromContext to parse context docker endpoint metadata.

Also remove dockerapi.NegotiateAPIVersion(ctx) which is already provided by dockerclient.NewClientWithOpts.

Signed-off-by: CrazyMax [email protected]

crazy-max avatar Aug 04 '22 13:08 crazy-max

which is already provided by dockerclient.NewClientWithOpts.

Could you point to what you mean by that.

It's ep.ClientOpts() actually my bad: https://github.com/docker/cli/blob/f1615facb1ca44e4336ab20e621315fc2cfb845a/cli/context/docker/load.go#L124

crazy-max avatar Aug 05 '22 09:08 crazy-max

PTAL @thaJeztah @tonistiigi

crazy-max avatar Nov 17 '22 10:11 crazy-max