sbx/shell是基于强化版Debian 13构建的无代理通用Shell沙箱镜像,内置bash、git、apt、Docker引擎及各类常用命令行开发工具,可提供隔离的文件系统与网络环境,也可作为基础层叠加各类Agent扩展组件使用。
[!NOTE] Experimental: Sandbox Kit v3
This kit uses the experimental https://github.com/docker/sandbox-kit-spec, specifically https://github.com/docker/sandbox-kit-spec/blob/main/docs/spec/SPEC-v3.md. The format and runtime behavior may change before v3 is stable.
shell
A sandbox with no agent in it: the hardened Debian 13 shell template with a login shell as its launch command. bash, git, apt, a Docker engine with compose and buildx, curl, gh, jq, make, gcc, Python 3 and Node with npm.
The descriptor and recipe are the examples/shell kit from
https://github.com/docker/sandbox-kit-spec, published here
so sbx can resolve it by name.
The recipe refreshes certificate trust from DHI's signed apt repository: uv 0.13.4, GitHub CLI 2.103.0, pip 26.2.2 (including its virtual-environment wheel), Node 24.22.1, Docker 29.9.2, Buildx 0.38.1, Compose 5.6.1 and containerd 2.4.2-1, or newer package revisions. The Docker and containerd binaries are rebuilt with patched Go; updating the installed compiler alone does not fix existing binaries. The base's Go toolchain and clipboard bridge already use patched Go 1.26.10 and are retained. No extra apt repository or standalone binary download is needed.
Two things to use it for:
- A plain sandbox. Isolated filesystem, isolated network, a Docker engine you can break without touching the host.
- The base an agent mixin layers onto. It declares no credentials, which is
what makes it composable: v3 gives each credential one owner across a set, so
a base that claimed
anthropiccould not hostclaude-mixin, and one that claimedopenaicould not hostcodex-mixin. This one claims nothing and hosts all of them.
Usage
consolesbx run docker.io/sbx/shell:latest
With an agent layered on:
consolesbx run --kit docker.io/sbx/claude-mixin:latest docker.io/sbx/shell:latest
Or from a git URL targeting this repo:
consolesbx run "git+https://github.com/docker/sbx-kits-contrib.git#dir=shell"
Provider credentials
This kit declares none. For the provider API keys an agentless sandbox used to carry, compose https://github.com/docker/sbx-kits-contrib/blob/v3/../shell-credentials beside it:
consolesbx run --kit docker.io/sbx/shell-credentials:latest docker.io/sbx/shell:latest
That adds anthropic, github, google, mistral, nebius, openai,
openrouter and xai, each injected by the sandbox proxy on requests to that
provider's hosts. It does not compose with an agent kit that owns one of those
services.
What it declares
sbx@1. The host launches the image's command and honors the image's user.- Network.
deb.debian.organddhi.io, the configured apt sources. Nothing else: a sandbox that needs more should declare it in its own kit or widen the policy for that sandbox. AGENTS.md. The profile file composed kits write their guidance into. A workload owns the filename; a mixin contributes a body without naming one.
No labels: the base already carries com.docker.sandboxes.flavor=shell and
com.docker.sandboxes.start-docker=true.
Installing packages
The base ships an empty apt cache, so refresh it before the first install:
consolesudo apt-get update && sudo apt-get install -y <package>
Both apt sources are in the allow list above, so this works under a deny-all policy without widening anything.
Launch command
ENTRYPOINT ["bash"] with CMD ["-l"], so the sandbox opens a login shell. A
v3 workload takes its binary from the entrypoint, so the kit states it rather
than inheriting the base's tini -- bash -l, whose binary would be tini.
Building
consolecd shell docker buildx build . -f shell.yaml --output type=cacheonly # validates cd .. && sbx kit inspect ./shell # what it resolved to
Building through shell.yaml is what validates the descriptor: the kit
frontend checks it during the build and fails on a bad one. sbx kit validate
does not accept a v3 source kit.
sbx 命名空间的其他可用镜像:
sbx/opencode
sbx/hermes-agent-image
sbx/pi-image
sbx/claude
sbx/claude-ollama
sbx/playwright
镜像拉取方式
您可以使用以下命令拉取该镜像。请将 <标签> 替换为具体的标签版本。如需查看所有可用标签版本,请访问 标签列表页面。
DockerHub 原生拉取命令
用户好评
来自真实用户的反馈,见证轩辕镜像的优质服务