agent-env-mcp
@brycepelletier/agent-env-mcp
可重用的宿主机侧 MCP 控制器,用于加固的 Linux 软件工程运行时。
0.3.1 信任域划分
Compose 运行时在同一工作树上有两个执行域:
agent:供 Software Engineer 工具使用。真实的.git目录被一个 root 所有的 tmpfs 挂载所遮蔽。git:仅供git_command使用。它能看见真实的.git目录,并且设置network_mode: none。
远程 Git/GitHub 操作不属于此包;它们应由独立的 GitHub MCP 信任域处理。
Related MCP server: anvil
工具
ensure_environmentlist_directoryread_filesearch_workspaceworkspace_editrun_commandgit_command
MCP 会在工具首次使用时,通过 MCP Roots 惰性地发现当前活动的 VS Code 工作区。无需 ${workspaceFolder} 启动时变量。
本地开发
npm run link链接状态下的用户级 VS Code MCP 配置:
"agent-env": {
"type": "stdio",
"command": "agent-env-mcp"
}要移除全局开发链接:
npm run unlink0.3.1 验收检查
在移除项目旧的 .devcontainer 之前:
ensure_environment执行成功,并报告/agent-env/environment/<project>。run_command能够构建项目。即使
run_command通过 Python/Node 间接调用 Git,也无法获取真实的 Git 分支/历史。git_command ["status", "--short", "--branch"]执行成功。Git 服务没有网络访问权限。
当前的 .git 遮蔽实现基于标准检出之上,其中 .git 是一个目录。对于使用 .git 文件的 Git worktree/submodule,应拒绝此类仓库形式,或由未来的挂载策略处理,之后才能将此运行时视为已针对这些仓库形式加固。
This server cannot be deployed
Maintenance
Related MCP Connectors
Persistent cloud workspaces for AI agents: run commands, edit files, use git and a browser.
Linux microVM sandboxes for AI agents: run commands, files, processes, pause and wake.
Git-backed platform for skills, tools, and context for AI agents
Remote Linux boxes for coding agents: Docker, a browser, screenshots, logs, human takeover.
Related MCP Servers
- FlicenseNot gradedqualityCmaintenanceProvides AI coding agents with a secure, sandboxed environment for executing coding tasks including file operations, command execution, and testing. Features session management, policy enforcement, and Docker-based sandboxing for safe code execution and development workflows.-
- AlicenseNot gradedqualityCmaintenanceA throwaway Docker sandbox for agents to run code and shell commands safely.5 npmMIT
- FlicenseNot gradedqualityCmaintenanceEnables AI agents to safely execute Python, JavaScript, and Bash code in an isolated Docker sandbox with strict security constraints.1-
- AlicenseAqualityBmaintenanceEnables AI coding agents to safely execute commands, run tests, and modify project files inside disposable, policy-enforced Docker sandboxes that are isolated from the host machine and its credentials.15MIT