In this quickstart, you’ll install Container Use, connect it to your coding agent, and experience the core workflow: agents work in isolated environments while your files stay untouched, then review and decide what to do with their work.

1. Install Container Use

Make sure you have Docker and Git installed before starting.
brew install dagger/tap/container-use
container-use version   # → confirms install

2. Point your agent at Container Use

Container Use works with any MCP-compatible agent: Just add container-use stdio as an MCP server. This example uses Claude Code but you can view instructions for other agents.
1

Add MCP Configuration

cd /path/to/repository
claude mcp add container-use -- container-use stdio
2

Add Agent Rules (Optional)

Save CLAUDE.md file at the root of your repository:
curl https://raw.githubusercontent.com/dagger/container-use/main/rules/agent.md >> CLAUDE.md
3

Trust Only Container Use Tools (Optional)

For maximum security, restrict Claude Code to only use Container Use tools:
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

3. Run your first parallel task

Let’s create a demo repository and ask your agent to build something:
# start a demo repo
mkdir hello
cd hello
git init
touch README.md
git add README.md
git commit -m "initial commit"
Now prompt your agent to do something:
"Create a Flask hello‑world app in Python."
After a short run you’ll see something like:
✅ App running at http://127.0.0.1:58455
🔍 View files:  container-use checkout {id}
📋 Dev log:     container-use log {id}
Replace {id} with your actual environment ID like fancy-mallard
Notice your local directory is still empty, because the agent worked in an isolated environment:
$ ls
README.md
You can see all environments with container-use list.

4. Review the work

See what the agent changed:
container-use diff {id}
Check out the environment locally to explore:
container-use checkout {id}

5. Accept or discard

Accept the work and keep the agent’s commit history:
container-use merge {id}
Or stage the changes to create your own commit:
container-use apply {id}
🎉 That’s it – you’ve run an agent in parallel, checked its work, and decided what to do with it.