sha256:068333fee071839dd8d3397dc9e1ec329a24ab6a85a3846feba16f02668a791e
Last pushed
4 days by dhibot
Type
Sandbox Kit
Manifest digest
sha256:068333fee071839dd8d3397dc9e1ec329a24ab6a85a3846feba16f02668a791e
schemaVersion: "3"
displayName: Pi ACP adapter
author: Docker, Inc. https://docker.com
description: ACP adapter overlay for pi. Requires the pi-mixin kit.
sourceUrl: https://github.com/docker-hardened-images/definitions
version: 0.0.35
licenses:
- MIT
kind: mixin
provides:
- [email protected]
requires:
- pi
capabilities:
- type: com.docker.sandbox/acp@1
optional: true
config:
agent: pi
command:
- pi-acp
description: Drive pi sessions over the Agent Client Protocol
- type: com.docker.sandbox/agent-context@1
optional: true
config:
content: |
## Pi ACP adapter
`pi-acp` is installed at `/usr/local/bin/pi-acp`. It is an Agent Client Protocol (ACP) server on stdio: a
client spawns it and drives a pi session through the protocol. It is not an interactive command — with no
client on the other end of stdio it sits silent, so do not run it from this shell to "check" it.
Host tools must attach it to a non-TTY stdin/stdout stream, for example `sbx exec -i <sandbox> pi-acp`. In
Zed, configure an agent server whose command runs that.
The adapter spawns the same `pi` binary this sandbox already has (the one `command -v pi` finds, unless
`PI_ACP_PI_COMMAND` names another) and talks to it over pi's own JSONL RPC (`pi --mode rpc`). Authentication
is therefore the surface `pi` uses: the proxy-mediated Anthropic credential behind `ANTHROPIC_API_KEY` and
`~/.pi/agent/auth.json`. If `pi` works here, the adapter works with no extra setup and nothing separate to log
in to. Sessions created through ACP and interactive `pi` runs share the same `~/.pi/agent/sessions` store.
Two gaps worth knowing before you rely on them. The adapter implements no `session/request_permission`: pi
runs tools locally without surfacing a pre-execution intent, so there is no ACP-level approval step and the
container is the only boundary. And ACP `mcpServers` passed in `session/new` do not reach pi: the adapter
forwards them with a `--mcp-config` flag that stock pi does not register (it comes from the third-party
`pi-mcp-adapter` extension, which this image does not ship), so they are silently dropped. Configure MCP
servers through `pi mcp add` instead — the sandbox gateway is already registered that way.
- type: com.docker.sandbox/agent-context@2
optional: true
config:
content: |
## Pi ACP adapter
`pi-acp` is installed at `/usr/local/bin/pi-acp`. It is an Agent Client Protocol (ACP) server on stdio: a
client spawns it and drives a pi session through the protocol. It is not an interactive command — with no
client on the other end of stdio it sits silent, so do not run it from this shell to "check" it.
Host tools must attach it to a non-TTY stdin/stdout stream, for example `sbx exec -i <sandbox> pi-acp`. In
Zed, configure an agent server whose command runs that.
The adapter spawns the same `pi` binary this sandbox already has (the one `command -v pi` finds, unless
`PI_ACP_PI_COMMAND` names another) and talks to it over pi's own JSONL RPC (`pi --mode rpc`). Authentication
is therefore the surface `pi` uses: the proxy-mediated Anthropic credential behind `ANTHROPIC_API_KEY` and
`~/.pi/agent/auth.json`. If `pi` works here, the adapter works with no extra setup and nothing separate to log
in to. Sessions created through ACP and interactive `pi` runs share the same `~/.pi/agent/sessions` store.
Two gaps worth knowing before you rely on them. The adapter implements no `session/request_permission`: pi
runs tools locally without surfacing a pre-execution intent, so there is no ACP-level approval step and the
container is the only boundary. And ACP `mcpServers` passed in `session/new` do not reach pi: the adapter
forwards them with a `--mcp-config` flag that stock pi does not register (it comes from the third-party
`pi-mcp-adapter` extension, which this image does not ship), so they are silently dropped. Configure MCP
servers through `pi mcp add` instead — the sandbox gateway is already registered that way.
args:
version:
required: true
description: pi-acp release the overlay carries
pattern: ^[0-9]+\.[0-9]+\.[0-9]+$
buildArg: VERSION