Skip to content
Install
mcp-registry/Container Use
Container Use logo

Container Use

Author: dagger

Description: Open-source MCP server + CLI that provides containerized, isolated development environments for coding agents (Claude Code, Cursor, other MCP clients). Powered by Dagger; runs as an MCP stdio server to let multiple agents work in parallel containers/branches with logs, terminal attach, and git-based review.

Stars: 3.6k

Forks: 173

License: Apache License 2.0

Category: Open Source

Overview

Installation

## Install
### macOS (recommended)
brew install dagger/tap/container-use
### All platforms
curl -fsSL https://raw.githubusercontent.com/dagger/container-use/main/install.sh | bash
## Setup with your MCP-compatible agent
Container Use setup is: add `container-use stdio` as an MCP server.
### Example (Claude Code)
cd /path/to/repository claude mcp add container-use -- container-use stdio
### Optional: add agent rules
curl https://raw.githubusercontent.com/dagger/container-use/main/rules/agent.md >> CLAUDE.md
### Notes
- The `container-use` command is also available as `cu` (shortcut). Both work identically:
- `container-use stdio`
- `cu stdio`
### Additional setup guides
- Complete setup guide for multiple agents (Cursor, Goose, VSCode, etc.): [https://container-use.com/quickstart](https://container-use.com/quickstart)

01

container-use stdio

Run the Container Use MCP server over stdio for use by MCP-compatible agents (e.g., Claude Code, Cursor).

02

cu stdio

Shortcut alias for `container-use stdio`; runs the same MCP server over stdio.

FAQs

What happens when two Container Use agents modify the same file on different environment branches, and how do I resolve merge conflicts?

Each agent writes to its own container-use/<env_name> branch, so conflicts only surface when you merge those branches into your main branch. Resolve them using standard Git conflict resolution: run cu merge <env_name>, Git will mark conflicts in the file, manually edit to choose which agent's changes to keep, then git add and git commit to complete the merge.

Can I customize the Docker image or container configuration used by Container Use for each agent environment?

Yes, Container Use supports customization through the `environment_config` MCP tool mentioned in the server's API. You can specify base images, environment variables, and mount points when creating or configuring an environment. Configuration options are typically set during `environment_create` or modified afterward, allowing per-agent container tuning for specific language runtimes, dependencies, or toolchains your workflow requires.

How does Container Use's branch-per-agent Git workflow compare to using regular Git worktrees for parallel development?

Container Use automates branch creation, container provisioning, and MCP tool integration for AI agents, whereas Git worktrees require manual setup. Worktrees share the repository database and avoid duplication, making them lighter weight, but lack containerized isolation. Agents can still interfere through shared system resources, processes, or non-Git state that containers explicitly prevent.

What are the performance overhead and resource requirements of running multiple Container Use agent containers simultaneously?

The content does not specify CPU, memory, or disk overhead per container. Expect standard Docker container footprint: roughly 100-500 MB RAM per environment depending on toolchain, plus incremental CPU during active tasks. Performance scales with host resources and Docker storage driver efficiency. Monitor with `docker stats` to track actual consumption across concurrent agents.

How do I set up Container Use to run multiple Claude Code agents in parallel on the same codebase?

Install Container Use via brew or curl, then run `claude mcp add container-use -- container-use stdio` in your project directory. Create separate environments for each agent with `environment_create`, assign each agent to its own environment, and launch parallel Claude Code sessions. Each agent automatically works in its own container and dedicated Git branch.

How do I roll back or discard changes made by a Container Use agent if the results are unsatisfactory?

You have two options: discard the entire environment branch by deleting it with `git branch -D container-use/env_name`, or use `environment_checkpoint` to create restore points during agent work and revert to an earlier checkpoint. Since changes never touch your working tree, simply abandoning the branch leaves your main codebase untouched.

License: Apache License 2.0
Updated 2/23/2026