{"slug": "discobox-ai-coding-agents-in-disposable-sandboxes", "title": "DiscoBox: AI Coding Agents in Disposable Sandboxes", "summary": "Discobox launched a tool that runs AI coding agents such as Claude Code, Codex, and OpenCode in disposable sandboxed environments, each with its own clone of a repository, passwordless sudo, nested Docker, a desktop, and a browser. Developers install Discobox via Homebrew or an install script on macOS, Linux, and Windows, then use the `discobox apply` command to cherry-pick an agent's commits back onto their current branch, keeping the original checkout untouched. The tool is under active development and lets multiple agent sessions run against one repository without competing for the same files, branches, ports, or databases.", "body_md": "Discobox runs coding agents in disposable environments, each with its own copy of your source. Agents have passwordless sudo, nested Docker, a desktop, and a browser, and you can connect through a terminal, SSH, or your editor.\n\nRun as many agent sessions against one repository as you like, each in its own box, while your own checkout stays yours. Source moves the way it already does with git: a box clones your repository, the agent commits, and you merge those commits back to your machine or push them as a pull request.\n\nClaude Code, Codex, and OpenCode are included; other terminal agents can be packaged in an image. Discobox supports macOS, Linux, and Windows and is under active development.\n\nInstall with Homebrew, on macOS or Linux:\n\n```\nbrew install discobox-ai/tap/discobox\n```\n\nOr with the install script:\n\n```\ncurl -sSfL https://discobox.ai | sh\n```\n\nOn Windows, from PowerShell:\n\n```\nirm https://discobox.ai/install.ps1 | iex\n```\n\nEach of those installs the stable channel. [Release channels](#release-channels)\ncovers the newer ones and how to pin a version.\n\nOpen the launcher from your repository to create a box:\n\n```\ncd ~/src/my-project\ndiscobox\n```\n\nWork with the agent and have it commit the changes inside the box. From your original repository, apply those commits to your working tree:\n\n```\ndiscobox apply\n```\n\nAn agent working in your checkout ties it up. You wait for it to finish, and a second agent in the same directory edits the same files, switches the same branch, and competes for the same ports and databases. Each box instead has its own copy of the source, its own git repository, and its own services and Docker. You can start a bug fix, a feature, and an experiment you may throw away, each in its own box, and keep working in your own checkout while they run.\n\n```\ndiscobox -d -p 'fix the flaky retry test'\ndiscobox -d -p 'add pagination to the users endpoint'\ndiscobox -d -p 'try replacing the ORM with sqlc'\ndiscobox ls\n```\n\nThere is no special sync layer. Give an agent a computer of its own and it needs the source the way you would on a new machine: clone the repository, make changes, then merge them back or open a pull request. A box does exactly that, so the only questions are where it clones from and where the work goes.\n\n``` php\nflowchart LR\n  repo[\"Your repository\"] -- \"clone\" --> a[\"Box A\"]\n  repo -- \"clone\" --> b[\"Box B\"]\n  repo -- \"clone\" --> c[\"Box C\"]\n  a -- \"discobox apply\" --> repo\n  b -- \"discobox apply\" --> repo\n  c -- \"git push\" --> host[\"Your Git host: a branch or pull request\"]\n```\n\n**Where a box clones from.** Your local repository, at the commit you have\nchecked out. If your working tree has uncommitted changes, Discobox asks whether\nto bring them along; they arrive as uncommitted changes on that same commit. In\nthe box, `origin` is your repository, read-only: the agent can fetch from it but\ncannot push to it, and nothing it does touches your files. `-i` brings more\nsources into the same box, either another local checkout or a remote URL, whose\n`origin` is then that remote.\n\n**Where the work goes.** The agent commits in the box. From there, the work goes\nback the same two ways it does today:\n\n- **Merge it back to your machine** with`discobox apply` , run from your\nrepository. It fetches the box's commits and cherry-picks them onto your\ncurrent branch, keeping each commit's message, author, and boundaries. The\nresult is ordinary history: review it with`git log` , amend or reorder it, and\npush it like any other commit.\n  - The cherry-pick runs in a scratch worktree, and your branch moves only if\nevery commit applies cleanly. On a conflict nothing changes, and apply prints\nthe `git cherry-pick` command that reproduces it.\n  - Only committed work is applied. A box with uncommitted changes is skipped, so nothing lands from a half-finished state.\n  - Discobox records what it applied, so applying the same box again brings over only the commits made since.\n- The cherry-pick runs in a scratch worktree, and your branch moves only if\nevery commit applies cleanly. On a conflict nothing changes, and apply prints\nthe \n- **Push to a remote and open a pull request** from inside the box, with`git push` and`gh` , the way you would from your laptop. The box never holds your\nGit host token: you pass it in as a secret, or the agent requests access and\nyou grant it, and the box sees only a placeholder (see[Isolation and credentials](#isolation-and-credentials) ).\n\nBoxes never see each other; their work meets in your repository. Once one box is\napplied, the others can build on it. Inside a box,\n`git fetch origin && git rebase origin/<branch>` picks up everything on your\nbranch, including your own commits and the work of other boxes you applied. When two changes overlap, the\nagent resolves the conflict in its box and you apply the rebased result, so the\nmerge work stays out of your checkout.\n\nWhere a box cannot read your repository directly, such as one running on another\nmachine, the client pushes your new commits into it while you are attached, and\n`discobox push` sends them on demand.\n\n- **Terminal and SSH:** Use the TUI or`discobox shell` . SSH configuration syncs\nautomatically when a box is created, so`ssh $DISCOBOX_ID` works without manual\nsetup. You can also connect by box name.\n- **Editor and tools:** Use`discobox tools vscode` or`discobox tools zed` to\nopen VS Code or Zed in the box's working directory;`discobox tools ls` lists\nevery tool a box offers. Declare your own as a`.yaml` or a front-matter script\nin the box's`.discobox/tools` or in your own config directory's`discobox/tools` (ADR 0125). Other editors with SSH remote support can also\nconnect directly.\n- **Desktop:** Access the box's graphical desktop and browser through VNC or\nnoVNC, using port forwarding.\n- **Toolchain:** direnv loads the project's declared environment, including\nNix or mise configuration.\n- **Automation:** The CLI and OpenAPI API support scripting box creation,\ncredential grants, and collecting results.\n\nDiscobox uses VM and container isolation. Agents can install packages and run commands inside the box without approval prompts. Outbound traffic passes through a proxy with a separate mTLS identity for each box, destination policy, and request auditing.\n\nManaged credentials remain outside the box. Agents receive placeholders called sentinels; the proxy substitutes the real credential only for its bound domain. An agent can request additional access, which a human grants with a host scope and an expiry.\n\nAn LLM judge checks privileged credential use against grants written in English. The judge currently runs inside the box, so it is a guardrail rather than a security boundary against a compromised agent.\n\nSee [discobox.ai](https://discobox.ai) for the full overview and\n[architecture](https://discobox.ai/architecture).\n\nEvery release is published as a prerelease and marked stable by hand later, once it has been in use for a while. That gives three channels, each newer and less proven than the one before:\n\n- **stable** — the newest release marked stable. This is what you get when you\nask for nothing in particular.\n- **latest** — the newest`vX.Y.Z` release, stable or not. A release joins it\nthe moment it is cut.\n- **edge** — the newest release of any kind, including the`-alpha` ,`-beta` ,\nand`-rc` builds cut to try a change before it becomes a release.\n\nThe tap carries stable and latest as two formulae. `discobox-dev` installs\nbeside `discobox` and runs under its own name, so you can keep both:\n\n```\nbrew install discobox-ai/tap/discobox      # stable, runs as discobox\nbrew install discobox-ai/tap/discobox-dev  # latest, runs as discobox-dev\n```\n\nThe two share one state directory, one configuration, and one downloaded server, so their servers cannot run at the same time; stop one before starting the other. There is no edge formula — use the install script for that.\n\n```\ncurl -sSfL https://discobox.ai | sh                         # stable\ncurl -sSfL https://discobox.ai | sh -s -- --channel latest  # latest\ncurl -sSfL https://edge.discobox.ai | sh                    # edge\nirm https://discobox.ai/install.ps1 | iex                   # stable\nirm https://edge.discobox.ai/install.ps1 | iex              # edge\n$env:DISCOBOX_CHANNEL = 'latest'; irm https://discobox.ai/install.ps1 | iex\n```\n\nUnlike the tap, the script installs whichever channel you ask for as `discobox`,\nover whatever is already there. Pass `--dir` or `-InstallDir` to keep two of\nthem side by side.\n\nPin one release instead of a channel:\n\n```\ncurl -sSfL https://discobox.ai | sh -s -- --version v0.10.1\n& ([scriptblock]::Create((irm https://discobox.ai/install.ps1))) -Version v0.10.1\n```\n\nBoth scripts take `--channel`, `--version`, `--dir`, and `--stage` — `-Channel`,\n`-Version`, `-InstallDir`, `-Stage`, and `-NoModifyPath` in PowerShell — and\nread `DISCOBOX_CHANNEL`, `DISCOBOX_VERSION`, `DISCOBOX_INSTALL_DIR`, and\n`DISCOBOX_INSTALL_STAGE` from the environment, which is the only way to pass an\noption through `iex`. A flag beats the environment, and a version beats a\nchannel. `install.sh --help` lists the rest; `install.ps1` documents them in\nits header comment.\n\nEither way you install the client only. The Discobox server is a separate\nprogram, downloaded the first time something needs one locally and checked\nagainst the digests the client carries; `--stage` fetches it during the install\ninstead of on first use.\n\nTo remove Discobox's data, downloaded servers and images, and configuration,\nrun `discobox admin uninstall`. It lists what it will delete and asks first, and\nleaves the `discobox` command for your package manager to remove.\n\nAsk questions, share what you are building, and follow development on\n[Discord](https://discord.gg/BSFr7Fa7f2).\n\nSee [LICENSE](https://github.com/discobox-ai/discobox/blob/main/LICENSE).", "url": "https://wpnews.pro/news/discobox-ai-coding-agents-in-disposable-sandboxes", "canonical_source": "https://github.com/discobox-ai/discobox", "published_at": "2026-09-22 19:29:13+00:00", "updated_at": "2026-09-22 19:54:17.396103+00:00", "lang": "en", "topics": ["ai-agents", "ai-tools", "developer-tools", "ai-products"], "entities": ["Discobox", "Claude Code", "Codex", "OpenCode", "Homebrew", "macOS", "Linux", "Windows"], "alternates": {"html": "https://wpnews.pro/news/discobox-ai-coding-agents-in-disposable-sandboxes", "markdown": "https://wpnews.pro/news/discobox-ai-coding-agents-in-disposable-sandboxes.md", "text": "https://wpnews.pro/news/discobox-ai-coding-agents-in-disposable-sandboxes.txt", "jsonld": "https://wpnews.pro/news/discobox-ai-coding-agents-in-disposable-sandboxes.jsonld"}}