{"id":28462229,"url":"https://github.com/dagger/container-use","last_synced_at":"2025-06-11T23:02:43.586Z","repository":{"id":295857401,"uuid":"989346537","full_name":"dagger/container-use","owner":"dagger","description":"Development environments for coding agents. Enable multiple agents to work safely and independently with your preferred stack.","archived":false,"fork":false,"pushed_at":"2025-06-05T17:45:33.000Z","size":356,"stargazers_count":102,"open_issues_count":2,"forks_count":6,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-05T18:37:45.934Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dagger.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-05-23T23:18:43.000Z","updated_at":"2025-06-05T18:28:10.000Z","dependencies_parsed_at":"2025-06-05T18:38:14.490Z","dependency_job_id":"62ef4cce-3533-42d9-8967-76fe8d59a8e4","html_url":"https://github.com/dagger/container-use","commit_stats":null,"previous_names":["aluzzardi/container-use","dagger/container-use"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dagger%2Fcontainer-use","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dagger%2Fcontainer-use/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dagger%2Fcontainer-use/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dagger%2Fcontainer-use/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dagger","download_url":"https://codeload.github.com/dagger/container-use/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dagger%2Fcontainer-use/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":258509783,"owners_count":22712737,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-06-07T04:08:44.032Z","updated_at":"2025-06-11T23:02:43.579Z","avatar_url":"https://github.com/dagger.png","language":"Go","readme":"\u003cdiv align=\"center\"\u003e\n  \u003cimg src=\"./_assets/container-use.png\" align=\"center\" alt=\"Container use: Development environments for coding agents.\" /\u003e\n  \u003ch1 align=\"center\"\u003econtainer-use\u003c/h2\u003e\n  \u003cp align=\"center\"\u003eContainerized environments for coding agents. (📦🤖) (📦🤖) (📦🤖)\u003c/p\u003e\n  \u003cp align=\"center\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/stability-experimental-orange.svg\" alt=\"Experimental\" /\u003e\n    \u003ca href=\"https://opensource.org/licenses/Apache-2.0\"\u003e\n      \u003cimg src=\"https://img.shields.io/badge/License-Apache_2.0-blue.svg\"\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://discord.gg/UhXqKz7SRM\"\u003e\n      \u003cimg src=\"https://img.shields.io/discord/707636530424053791?logo=discord\u0026logoColor=white\u0026label=Discord\u0026color=7289DA\" alt=\"Discord\"\u003e\n    \u003c/a\u003e\n  \u003c/p\u003e\n\u003c/div\u003e\n\n**Container Use** lets each of your coding agents have their own containerized environment. Go from babysitting one agent at a time to enabling multiple agents to work safely and independently with your preferred stack.\n\n\u003cp align='center'\u003e\n    \u003cimg src='./_assets/demo.gif' width='700' alt='container-use demo'\u003e\n\u003c/p\u003e\n\nIt's an open-source MCP server that works as a CLI tool with Claude Code, Cursor, and other MCP-compatible agents.\n\n* 📦 **Isolated Environments**: Each agent gets a fresh container in its own git branch - run multiple agents without conflicts, experiment safely, discard failures instantly.\n* 👀 **Real-time Visibility**: See complete command history and logs of what agents actually did, not just what they claim.\n* 🚁 **Direct Intervention**: Drop into any agent's terminal to see their state and take control when they get stuck.\n* 🎮 **Environment Control**: Standard git workflow - just `git checkout \u003cbranch_name\u003e` to review any agent's work.\n* 🌎 **Universal Compatibility**: Works with any agent, model, or infrastructure - no vendor lock-in.\n\n---\n\n🦺 This project is in early development and actively evolving. Expect rough edges, breaking changes, and incomplete documentation. But also expect rapid iteration and responsiveness to feedback.\n\n---\n\n## Install\n\n```sh\ncurl -fsSL https://raw.githubusercontent.com/dagger/container-use/main/install.sh | bash\n```\n\nThis will check for Docker \u0026 Git (required), detect your platform, and install the latest `cu` binary to your `$PATH`.\n\n## Building\n\nTo build the `cu` binary without installing it to your `$PATH`, you can use either Dagger or Go directly:\n\n### Using Go\n\n```sh\ngo build -o cu ./cmd/cu\n```\n\n### Using Dagger\n\n```sh\ndagger call build --platform=current export --path ./cu\n```\n\n## Integrate Agents\n\nEnabling `container-use` requires 2 steps:\n\n1. Adding an MCP configuration for `container-use` corresponding to the repository.\n2. (Optional) Adding a rule so the agent uses containarized environments.\n\n### [Claude Code](https://docs.anthropic.com/en/docs/claude-code/tutorials#set-up-model-context-protocol-mcp)\n\nAdd the container-use MCP:\n\n```sh\ncd /path/to/repository\nnpx @anthropic-ai/claude-code mcp add container-use -- \u003cfull path to cu command\u003e stdio\n```\n\nSave the CLAUDE.md file at the root of the repository. Alternatively, merge the instructions into your own CLAUDE.md.\n\n```sh\ncurl https://raw.githubusercontent.com/dagger/container-use/main/rules/agent.md \u003e\u003e CLAUDE.md\n```\n\n### [goose](https://block.github.io/goose/docs/getting-started/using-extensions#mcp-servers)\n\nAdd this to `~/.config/goose/config.yaml`:\n\n```yaml\nextensions:\n  container-use:\n    name: container-use\n    type: stdio\n    enabled: true\n    cmd: cu\n    args:\n    - stdio\n    envs: {}\n```\n\n### [Cursor](https://docs.cursor.com/context/model-context-protocol)\n\n```sh\ncurl --create-dirs -o .cursor/rules/container-use.mdc https://raw.githubusercontent.com/dagger/container-use/main/rules/cursor.mdc\n```\n\n### [VSCode](https://code.visualstudio.com/docs/copilot/chat/mcp-servers) / [GitHub Copilot](https://docs.github.com/en/copilot/customizing-copilot/extending-copilot-chat-with-mcp)\n\nThe result of the instructions above will be to update your VSCode settings with something that looks like this:\n\n```json\n    \"mcp\": {\n        \"servers\": {\n            \"container-use\": {\n                \"type\": \"stdio\",\n                \"command\": \"cu\",\n                \"args\": [\n                    \"stdio\"\n                ]\n            }\n        }\n    }\n```\n\nOnce the MCP server is running, you can optionally) update the instructions for copilot using the following:\n\n```sh\ncurl --create-dirs -o .github/copilot-instructions.md https://raw.githubusercontent.com/dagger/container-use/main/rules/agent.md\n```\n\n### [Kilo Code](https://kilocode.ai/docs/features/mcp/using-mcp-in-kilo-code)\n\n`Kilo Code` allows setting MCP servers at the global or project level.\n\n```json\n{\n  \"mcpServers\": {\n    \"container-use\": {\n      \"command\": \"replace with pathname of cu\",\n      \"args\": [\n        \"stdio\"\n      ],\n      \"env\": {},\n      \"alwaysAllow\": [],\n      \"disabled\": false\n    }\n  }\n}\n```\n\n## Examples\n\n| Example | Description |\n|---------|-------------|\n| [hello_world.md](examples/hello_world.md) | Creates a simple app and runs it, accessible via localhost HTTP URL |\n| [parallel.md](examples/parallel.md) | Creates and serves two variations of a hello world app (Flask and FastAPI) on different URLs |\n| [security.md](examples/security.md) | Security scanning example that checks for updates/vulnerabilities in the repository, applies updates, verifies builds still work, and generates patch file |\n\n### Run with [Claude Code](https://www.anthropic.com/claude-code)\n\n```console\ncat ./examples/hello_world.md | claude --dangerously-skip-permissions\n```\n\n### Run with [goose](https://block.github.io/goose/)\n\n```console\ngoose run -i ./examples/hello_world.md -s\n```\n\n### Run with [Kilo Code](https://kilocode.ai/) in `vscode`\n\nPrompt as in `parallel.md` but add a sentence 'use container-use mcp'\n\n## Watch your agents work\n\nYour agents will automatically commit to a container-use remote on your local filesystem. You can watch the progress of your agents in real time by running:\n\n```console\ncu watch\n```\n\n## How it Works\n\ncontainer-use is an Model Context Protocol server that provides Environments to an agent. Environments are an abstraction over containers and git branches powered by dagger and git worktrees. For more information, see [environment/README.md](environment/README.md).\n","funding_links":[],"categories":["Sandboxing \u0026 Execution","Code Execution \u0026 Automation Mcp Servers","📦 Other","پیاده‌سازی‌های سرور","Agents","Code Execution","Go","HarmonyOS","Developer Tools","MCP Ecosystem","Tooling 🧰"],"sub_categories":["Wiki \u0026 Collaboration","👨‍💻 \u003ca name=\"code-execution\"\u003e\u003c/a\u003eاجرای کد","Windows Manager","How to Submit","Servers","General"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdagger%2Fcontainer-use","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdagger%2Fcontainer-use","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdagger%2Fcontainer-use/lists"}