chore: evaluate Docker Go SDK for context-aware container runtime support
维护者通常 1 天内回复
@SafeeImran 已经在做这个了。
开始于 2026年9月26日。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 45/100
调研方向
The evaluation focuses on the container client in pkg/connectors. Start by reviewing the current github.com/docker/docker/client usage there. Create a proof-of-concept using docker/go-sdk to test the required capabilities, especially context resolution for Docker Desktop. Run existing container-client tests to ensure compatibility. The outcome is a recommendation, not a full migration.
由索引模型根据 Issue 内容生成。
描述
Description
Evaluate the official docker/go-sdk as a replacement for the current low-level github.com/docker/docker/client integration.
The current client reads DOCKER_HOST but does not resolve Docker CLI contexts. Consequently, microcks-cli may try /var/run/docker.sock even when Docker Desktop uses the active desktop-linux context and exposes its socket at $HOME/.docker/run/docker.sock.
The Docker Go SDK provides Docker-context discovery, but it has not reached v1.0.0. We should verify that it supports all capabilities required by microcks-cli before adopting it.
Goals
- Test whether
docker/go-sdk/clientcorrectly resolves the active Docker context. - Verify that it supports all current container operations.
- Determine whether it can preserve Docker and Podman compatibility.
- Estimate the migration from
github.com/docker/dockerto the newer Docker/Moby API packages. - Produce a go/no-go recommendation.
Required capabilities
Verify support for:
- Pulling container images and streaming pull progress.
- Creating containers with port bindings and auto-remove.
- Starting and stopping containers.
- Inspecting whether a container exists.
- Closing the client cleanly.
- Docker API-version negotiation.
- Explicit
DOCKER_HOSTconfiguration. - Active Docker context resolution.
DOCKER_CONTEXToverrides.- Docker Desktop’s
$HOME/.docker/run/docker.sock. - Linux’s
/var/run/docker.sock. - Windows named pipes.
- Remote contexts and their TLS configuration.
- Podman through its Docker-compatible socket.
Compatibility scenarios
At minimum, test:
- Docker Desktop on macOS with the
/var/run/docker.sockcompatibility symlink disabled. - Docker Desktop on macOS with the compatibility symlink enabled.
- Explicit
DOCKER_HOST. - Local Docker Engine on Linux.
- Podman machine on macOS or Windows.
- Rootless Podman on Linux.
- A named Docker context.
- An unreachable or invalid context, ensuring the error is actionable.
Dependency assessment
Document:
- The exact
docker/go-sdkversion tested. - Its API stability and release status.
- Required changes to existing Docker API type imports.
- Interaction with
testcontainers-goandmicrocks.io/testcontainers-go. - Any dependency-version conflicts.
- Binary-size impact, if material.
- Whether adopting it requires a complete Moby API migration or can be isolated to
pkg/connectors.
Because the SDK is pre-v1, any adoption should pin an exact released version rather than a branch or pseudo-version.
Acceptance criteria
-
A small proof of concept exercises the operations currently used by
containerClient. -
The proof of concept successfully connects through the
desktop-linuxcontext without settingDOCKER_HOST. -
DOCKER_HOSTandDOCKER_CONTEXTprecedence is verified. -
Docker and Podman behavior is documented.
-
Existing container-client tests continue to pass or required changes are identified.
-
The issue concludes with one of:
- Adopt: create a focused migration issue with the required changes.
- Defer: document the missing capabilities or stability concerns and retain the current client.
- Reject: document the incompatibilities and the preferred alternative.
Non-goals
- Rewriting the complete container abstraction during the evaluation.
- Migrating production code before compatibility is demonstrated.
- Replacing the separate Testcontainers integration unless the evaluation identifies a concrete requirement.
- 主要语言
- Go
- 星标
- 59
- 派生
- 74
- 平均合并
- 4 天 5 小时
- 30 天内合并 PR
- 15
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
microcks/microcks-cli 的其他 Issue
-
Malformed local configuration is silently accepted and can be overwritten可能已有人在做 @aniket866 于 3 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 72/100
microcks/microcks-cli#615 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 82/100
microcks/microcks-cli#610 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 85/100
microcks/microcks-cli#608 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 88/100
microcks/microcks-cli#606 ·
维护者通常 1 天内回复
-
Windows test failures in MockFileSystem.Walk due to path separator可能已有人在做 @dipak0000812 于 3 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 82/100
microcks/microcks-cli#601 · 1 条评论 ·
维护者通常 1 天内回复
查看 microcks/microcks-cli 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 80/100
rishikanthc/Scriberr#506 ·
-
[Bug] rollingUpdatePartition panics when live StatefulSet replicas sit far below the desired count未关闭
难度 2/5 1-3 小时 新手友好度 78/100
sgl-project/rbg#547 ·
维护者通常 1 天内回复
-
area: frontend priority: normal
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
area/validator
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
TestAutonomousStop_ReportsObservedState fails under host load: 1s wall-clock ceiling vs 250ms cycle未关闭type:bug
难度 2/5 1-3 小时 新手友好度 65/100
nightgauge/nightgauge#2909 ·
维护者通常 1 天内回复