OpenAI Codex CLI on Docker Hardened Images for Docker Sandboxes
100K+
OpenAI's Codex CLI on Docker Hardened Images
| Name | Required | Default | Description |
|---|---|---|---|
model | Optional | | Codex model to use (config.toml `model`); empty keeps the CLI default |
reasoningEffort | Optional | | Reasoning effort (config.toml `model_reasoning_effort`); empty keeps the CLI default |
version | Required | — | Codex CLI release the image carries |
[email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/ca-certificates@20250419, deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/iputils-ping@20240905, deb/[email protected], deb/less@668, deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/tzdata@2026, deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected], deb/[email protected]| Type | Required | Description | |
|---|---|---|---|
com.docker.sandbox/sbx@1 | Required | — | |
com.docker.sandbox/network-policy@1 | Required | — | |
com.docker.sandbox/credential@1 | Optional | OpenAI API access (API key or ChatGPT OAuth) | |
com.docker.sandbox/lifecycle@1 | Required | — | |
com.docker.sandbox/agent-sessions@1 | Optional | — | |
com.docker.sandbox/agent-interactive-sessions@1 | Optional | — | |
com.docker.sandbox/agent-skills@1 | Optional | — | |
com.docker.sandbox/agent-context@1 | Optional | — | |
com.docker.sandbox/agent-context@2 | Optional | — | |
com.docker.sandbox/ssh-agent@1 | Optional | — | |
com.docker.sandbox/open-url@1 | Optional | — | |
Run the following command to install sbx on your machine.
brew install docker/tap/sbxwinget install Docker.sbxThis v3 workload Kit packages Codex for Docker Sandboxes. It includes the agent and a development environment. Start the workload to use Codex in an isolated workspace.
This Kit is built on Docker Hardened Images.
sbx run sbx/codex:latest /path/to/workspace
Set these arguments when creating the sandbox with --kit-arg <name>=<value>. Repeat the flag for multiple arguments.
Use --kit-arg <kit>.<name>=<value> to target one kit in a composition, as in the example below.
| Argument | Default | Description | Accepted values |
|---|---|---|---|
model | "" | Codex model to use (config.toml model); empty keeps the CLI default | Letters, digits, ., _, and -. |
reasoningEffort | "" | Reasoning effort (config.toml model_reasoning_effort); empty keeps the CLI default | Empty, none, minimal, low, medium, high, xhigh, max, ultra, or persistent. |
An empty value keeps the agent default. The model must be available to your provider account, and the selected model
must support the requested effort or thinking level. These are kit configuration inputs, separate from agent
command-line arguments passed after --.
sbx run sbx/codex:latest \
--kit-arg codex.model=gpt-5 --kit-arg codex.reasoningEffort=high \
/path/to/workspace
Bind an OpenAI API key on the host with sbx secret set openai. For a ChatGPT login, run
sbx secret set openai --oauth on the host. You can also sign in from Codex inside the sandbox. Host-bound credentials
remain proxy-managed.
The sandbox supplies the isolation for agent tool execution. Launch the kit through Docker Sandboxes and configure extra tool or MCP destinations in the runtime network policy as needed.
When SSH agent forwarding is enabled on the host (the default) and the host agent answers when the sandbox is created,
the sandbox gets that agent at runtime, so SSH and git can authenticate with your keys. Otherwise it runs without one
until it is recreated, unless a composed kit requires the agent, in which case the sandbox is not created. The grant is
unrestricted: private keys stay on the host, but any key the agent exposes can sign for anything the sandbox asks.
Composed with sbx/git-ssh-sign or sbx/github-ssh, those mixins still set up commit signing and GitHub's host keys,
but their bounds on the runtime agent no longer apply. sbx settings set ssh.agentForwardingEnabled false blocks new
agent connections in every sandbox.
The agent owns the Codex install. To move to a newer release inside a sandbox, run codex update. A new sandbox starts
from the release this Kit pins.
sbx/codex-acp provides the ACP adapter for the composed agent.sbx/codex-mixin provides the agent overlay for a compatible workload.sbx/codex-sessions provides host-backed conversation state.For the Kit format and capability contracts, see the Sandbox Kit v3 specification.
For runtime setup, see the Docker Sandboxes documentation. For provenance, SBOM, VEX, and image verification, see the Docker Hardened Images documentation.
Codex and OpenAI are trademarks of OpenAI, L.L.C. Product names and logos do not imply sponsorship or endorsement.