Docker Sandboxes – Disposable, isolated sandboxes for AI agents

Docker Sandboxes – Disposable, isolated sandboxes for AI agents

Docker Sandboxes – 为 AI 智能体提供的可丢弃、隔离式沙箱

Docker Sandboxes Run AI agents safely in local sandboxes. Disposable, isolated sandboxes for AI agents like Claude Code, Copilot CLI, Codex, OpenCode, and Kiro that need safe, unattended execution. Docker Sandboxes 可以在本地沙箱中安全地运行 AI 智能体。它为 Claude Code、Copilot CLI、Codex、OpenCode 和 Kiro 等需要安全、无人值守执行任务的 AI 智能体提供了可丢弃的隔离环境。


Get started

快速开始

macOS $ brew trust docker/tap && brew install docker/tap/sbx

Windows > winget install Docker.sbx

Linux (Ubuntu) $ curl -fsSL https://get.docker.com | sudo REPO_ONLY=1 sh $ sudo apt-get install docker-sbx


Sandboxes in action.

沙箱实战演示。

Watch an agent install packages, run Docker, modify configs, and execute unattended. Then dispose of the sandbox in one command. 观看智能体如何安装软件包、运行 Docker、修改配置并进行无人值守执行。任务完成后,只需一条命令即可销毁沙箱。


Why sandboxes

为什么需要沙箱?

Give agents the autonomy they need to get work done, safely. Agents do their best work when they have freedom. Sandboxes let them run fast without running wild, so speed and safety stop being a tradeoff. 赋予智能体完成工作所需的自主权,同时确保安全性。智能体在拥有自由时表现最佳。沙箱让它们能够快速运行而不会失控,从而使速度与安全不再是鱼与熊掌不可兼得的矛盾。

Filesystem | Network | Credentials 文件系统 | 网络 | 凭据

Need to enforce these controls across your whole team? That’s Docker AI Governance. 需要在整个团队中强制执行这些控制措施?这正是 Docker AI Governance 的作用。


Capabilities

核心功能

YOLO mode, safely. Each agent runs inside a dedicated microVM with your dev environment and only your project workspace mounted in. Agents can install packages, modify configs, and spin up their own Docker containers. Your host stays untouched. No manual review, no permission prompts, no supervision required. 安全地开启“YOLO 模式”。 每个智能体都在专用的微型虚拟机(microVM)中运行,仅挂载您的开发环境和项目工作区。智能体可以安装软件包、修改配置并启动自己的 Docker 容器,而您的宿主机始终保持不受影响。无需人工审核、无需权限提示、无需监督。

Customizable Safe Execution Network and filesystem controls you define. Enforceable org-wide with Docker AI Governance. 可定制的安全执行 由您定义网络和文件系统控制策略,并通过 Docker AI Governance 在全组织范围内强制执行。

MicroVM Isolation Hard security boundary from the host. Fast to Spin Up, Easy to Tear Down. 微型虚拟机隔离 与宿主机之间存在严格的安全边界。启动迅速,销毁简单。

Agents Can Use Docker Too Agents can spin up containers within Sandboxes. 智能体也能使用 Docker 智能体可以在沙箱内启动容器。

Real Dev Environment Install packages, run services, work unattended. 真实的开发环境 安装软件包、运行服务、无人值守工作。

One Sandbox for All Your Coding Agents Claude Code, Copilot CLI, Codex, Kiro, OpenCode. 适用于所有编码智能体的统一沙箱 支持 Claude Code、Copilot CLI、Codex、Kiro、OpenCode 等。

Default –dangerously-skip-permissions Use permissive modes with confidence. In fact, that’s the default. 默认开启 –dangerously-skip-permissions 自信地使用宽松模式。事实上,这是默认设置。


Works with leading coding agents

兼容主流编码智能体

“Every team is about to have their own team of AI agents doing real work for them. The question is whether it can happen safely. NanoClaw was built on the principle that you don’t trust agents with security, you build walls around them. Docker has been ahead of the curve on exactly this. Docker Sandboxes is what that looks like at the infrastructure level, making it possible for organizations to get the full value from agents without compromising on security.” — Gavriel Cohen, Creator of NanoClaw “每个团队都将拥有自己的 AI 智能体团队来处理实际工作。问题在于这能否安全地实现。NanoClaw 的构建原则是:不要在安全问题上信任智能体,而是在它们周围建立围墙。Docker 在这一点上一直走在行业前沿。Docker Sandboxes 在基础设施层面实现了这一点,使组织能够在不牺牲安全性的前提下,充分发挥智能体的价值。” — Gavriel Cohen, NanoClaw 创始人

“Docker Sandboxes let agents have the autonomy to do long-running tasks without compromising safety. We’re excited to integrate Sandboxes into Warp so that developers can run agents freely with a consistent environment, regardless of whether agents are running locally or in the cloud.” — Ben Navetta, Engineering Lead, Warp “Docker Sandboxes 让智能体拥有执行长期任务的自主权,同时不会损害安全性。我们很高兴将 Sandboxes 集成到 Warp 中,这样开发者无论是在本地还是云端运行智能体,都能在一致的环境中自由操作。” — Ben Navetta, Warp 工程主管


FAQ

常见问题解答

What is a sandbox for AI coding agents? A sandbox is a microVM isolated environment that protects your filesystem and network from agents running inside it. 什么是 AI 编码智能体沙箱? 沙箱是一个微型虚拟机(microVM)隔离环境,用于保护您的文件系统和网络免受内部运行的智能体的影响。

Which coding agents are supported? Out of the box we support Claude Code, Gemini CLI, Copilot CLI, Codex, OpenCode, Kiro. You can also create your own. 支持哪些编码智能体? 开箱即用支持 Claude Code、Gemini CLI、Copilot CLI、Codex、OpenCode 和 Kiro。您也可以创建自己的智能体。

What does “YOLO mode” mean, and is it safe? YOLO mode (—dangerously-skip-permissions) gives agents autonomy with no approval prompts. Essential for speed, but risky without guardrails. Sandboxes make it safe by isolating each agent inside a dedicated microVM. 什么是“YOLO 模式”,它安全吗? YOLO 模式(—dangerously-skip-permissions)赋予智能体自主权,无需审批提示。这对速度至关重要,但如果没有防护措施则存在风险。沙箱通过将每个智能体隔离在专用的微型虚拟机中,确保了其安全性。

How is a sandbox different from a VM? Sandboxes run fully isolated in microVMs, giving more isolation without paying the full cost of running a VM. This lets them do things that need more permissions safely, like running additional Docker containers. 沙箱与虚拟机(VM)有何不同? 沙箱在微型虚拟机中完全隔离运行,在提供更高隔离性的同时,无需支付运行完整虚拟机的全部成本。这使它们能够安全地执行需要更多权限的操作,例如运行额外的 Docker 容器。

What safety controls can I configure? To define these once and enforce them on every developer’s machine, see Docker AI Governance. 我可以配置哪些安全控制? 若要一次性定义并强制应用到每台开发人员的机器上,请参阅 Docker AI Governance。

Do I need Docker Desktop to use sandboxes? No. 使用沙箱需要 Docker Desktop 吗? 不需要。

What if I need additional admin controls? Installing Sandboxes covers core functionality. For centralized controls across a team such as network policies, filesystem rules, MCP governance: Docker AI Governance. 如果我需要额外的管理控制怎么办? 安装 Sandboxes 涵盖了核心功能。如需团队范围内的集中控制(如网络策略、文件系统规则、MCP 治理),请使用 Docker AI Governance。


Need More Control Over Your Sandboxes?

需要对沙箱进行更多控制?

With Docker Sandboxes, your developers get isolated environments to run agents freely and safely. When your team needs to go further with network access restrictions, filesystem policies, and centralized admin controls, we can help you configure the right setup. Docker AI Governance adds network access policies, filesystem controls, and org-wide MCP governance: defined once, enforced everywhere. 通过 Docker Sandboxes,您的开发人员可以获得隔离的环境,从而自由、安全地运行智能体。当您的团队需要进一步限制网络访问、制定文件系统策略和实施集中式管理控制时,我们可以帮助您配置合适的方案。Docker AI Governance 增加了网络访问策略、文件系统控制和全组织范围的 MCP 治理:一次定义,随处强制执行。

Talk to us about:

  • Network access policies for sandbox environments
  • Filesystem access controls and restrictions
  • Admin-level configuration for your team 咨询我们关于:
  • 沙箱环境的网络访问策略
  • 文件系统访问控制与限制
  • 团队级别的管理配置

[Talk to an expert] [咨询专家]

Thank you for your interest. The Docker Team will be in touch. 感谢您的关注。Docker 团队将与您联系。