[PoC] publish resolved stack to the engine compose stack extension point - #14040
Draft
ndeloof wants to merge 2 commits into
Draft
[PoC] publish resolved stack to the engine compose stack extension point#14040ndeloof wants to merge 2 commits into
ndeloof wants to merge 2 commits into
Conversation
ndeloof
force-pushed
the
poc-compose-stack-extension
branch
2 times, most recently
from
August 12, 2026 15:24
9d5946a to
14c14f3
Compare
Replace docker/cli with the cli-grpc branch (ndeloof/cli@b90d88ea3ad1) providing cli/grpc.Connect, the single way for CLI plugins to establish a gRPC connection to the daemon's API endpoint whatever the transport of the current context, falling back to the legacy upgrade endpoint when an intermediary does not relay HTTP/2. Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
Demo counterpart of the in-tree compose extension built on top of the moby extensions framework (moby/moby#53021): at the start of up, push the resolved Compose project (YAML) to the com.docker.compose.stack.v0 gRPC service the extended daemon exposes on its API endpoint. The connection goes through cli/grpc.Connect (docker/cli#7183), which hides the transport of the current context (unix/npipe socket, tcp with or without TLS, connection helpers) and the native-h2c vs legacy upgrade negotiation. Best effort: Unimplemented (no extension) and transport errors are debug-logged and up proceeds unchanged. Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
ndeloof
force-pushed
the
poc-compose-stack-extension
branch
from
August 13, 2026 11:49
14c14f3 to
d82a3a9
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What I did
PoC counterpart of ndeloof/docker#4 (an in-tree "compose stack" extension built on top of the moby extensions framework, moby/moby#53021), exploring the extension-point alternative to #13958's bespoke REST endpoint: at the start of
up, Compose publishes the resolved project definition (YAML) to thecom.docker.compose.stack.v0gRPC service the extended daemon exposes on its API endpoint. Discovery is the gRPC contract itself (Unimplemented= feature absent, transport error = no native gRPC), and the push is best-effort by construction.Two commits:
go.modreplace resolving cli/grpc: add gRPC connections to the Docker Engine's API endpoint cli#7183 (cli/grpc.Connect) — the connection helper hides the transport of the current context (unix/npipe socket, tcp ± TLS, connection helpers) and the native-h2c vs legacy-upgrade negotiation.Validated end to end against the DinD demo image from ndeloof/docker#4, both from inside (unix socket) and from the host over plain tcp (native h2c picked by the helper):
Against a stock engine 29 (Docker Desktop) the helper now falls back to the legacy
POST /grpcupgrade endpoint — its API proxy does not relay h2c even though the engine advertises API 1.55 — and the publish degrades to a cleanUnimplemented(extension point absent), confirming the fallback added to docker/cli#7183 by ndeloof/cli@b90d88ea3ad1.Pure demonstrator: no tests. Together with ndeloof/docker#4 this validates the model.