Commit graph

2 commits

Author SHA1 Message Date
Nicolas De Loof
be245666e4 refactor(compose): state the engine of the extracted packages once
internal/inspect and internal/containerops declared the same engine methods and one-off enum, and pkg/compose adapted them twice. Declare them in internal/engine, embed them in both Backend interfaces and keep a single adapter.

Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2026-10-29 11:59:43 +01:00
Nicolas De Loof
f877cf1525 refactor(containerops): move exec, cp, export and commit to internal/containerops
These four operations act from the outside on the container of a service.
They only need the Docker client, the concurrency bound, the event bus, the
dry-run switch, the Docker CLI (which owns the terminal streams) and the two
container lookups, so they move out of the flat pkg/compose package into
internal/containerops behind a Backend interface declaring exactly that.

composeService implements the interface in a new file and keeps Exec, Copy,
Export and Commit as one-line forwarders (the progress wrapper of the last
three stays there), so no caller changes. The now unused checkRelayTarget
forwarder is dropped. Behavior is unchanged: the cp test still runs through
the forwarders.

Part of #14396

Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2026-10-27 11:19:35 +01:00
Renamed from pkg/compose/commit.go (Browse further)