cd /news/ai-agents/parallel-development-with-claude-cod… · home › topics › ai-agents › article
[ARTICLE · art-151447] src=dev.to ↗ pub= topic=ai-agents verified=true sentiment=↑ positive

Parallel Development with Claude Code Without git worktree (container-use)

A developer has published a walkthrough of container-use, an MCP tool from Dagger that creates isolated per-branch development environments inside containers, allowing parallel Claude Code sessions without the extra directories that git worktree creates. The setup involves installing Dagger and container-use, registering the MCP server with `claude mcp add container-use -s user -- cu stdio`, and appending the project's agent.md rules to CLAUDE.md so Claude actually invokes the tool. Changes are pulled back into the local repo with `cu checkout <env_id>`, with `cu list` and `cu log` tracking environments and operation history.

by read2 min views2 publishedOct 16, 2026

You want to run multiple tasks in parallel with Claude Code, but you'd rather not have git worktree spawn a new directory every time. This post introduces "container-use," a tool that solves exactly that.

container-use is an MCP tool from Dagger. It creates isolated development environments inside containers on a per-branch basis, letting you do parallel development without polluting your local directory structure.

Aspect git worktree container-use
Directories A new directory is created Isolated inside a container
Environment isolation Files only The whole environment
Work log Only git history Operation history via cu log
Compatibility with ghq Tends to get messy No impact
sudo pacman -S dagger
yay -S container-use

For other OSes, see the official repository.

claude mcp add container-use -s user -- cu stdio

claude mcp list

If you see the following, you're good to go.

container-use: cu stdio - ✓ Connected

The official docs mark this as "optional," but without it Claude won't actually use container-use.

curl https://raw.githubusercontent.com/dagger/container-use/main/rules/agent.md >> CLAUDE.md

If you'd rather not get a confirmation prompt every time, launch with the following options.

claude --allowedTools mcp__container-use__environment_checkpoint,mcp__container-use__environment_create,mcp__container-use__environment_add_service,mcp__container-use__environment_file_delete,mcp__container-use__environment_file_list,mcp__container-use__environment_file_read,mcp__container-use__environment_file_write,mcp__container-use__environment_open,mcp__container-use__environment_run_cmd,mcp__container-use__environment_update
Command Description
cu list List environments
cu log <env_id> View the work log
cu checkout <env_id> Apply changes to a local branch
cu open <env_id> Open an existing environment
cu config Change settings like the base image

Once development is done, pull the changes from the container into your local repo with:

cu checkout <env_id>

Here's a concrete example.

Open two terminals and start a separate Claude Code session in each.

$ claude
> Issue #42のバグを修正して
bash
$ claude
> Issue #58の機能を実装して

Each Claude works inside its own container-use environment, so they don't step on each other.

1. Claudeが作業完了を報告
   ↓
2. cu list で環境IDを確認
   ↓
3. cu checkout <env_id> で変更を取り込み
   ↓
4. 通常通りレビュー → マージ

The more efficient parallel development gets, the faster review requests pile up.

As noted above, if you don't append the contents of agent.md to CLAUDE.md, Claude won't recognize container-use. Keep in mind that this has to be set up per project.

With container-use, you can do parallel development in Claude Code without scattering directories the way git worktree does.

Particularly recommended if you keep your repositories nicely organized with ghq.

This post was written with AI assistance and reviewed by the author.

── more in #ai-agents 4 stories · sorted by recency
── more on @claude code 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
→ Live at https://your-agent.zahid.host ✓
Get free account → Pricing
from €0/mo · no card required
LIVE [news/parallel-development…] indexed:0 read:2min 2026-10-16 · —