cursor
cursor copied to clipboard
Cursor starts duplicate GitHub MCP server instances
Bug Description
Cursor consistently starts 2 instances of the GitHub MCP server when it should only start 1. This results in duplicate Docker containers running the ghcr.io/github/github-mcp-server image.
Expected Behavior
Cursor should start exactly 1 GitHub MCP server instance as configured in ~/.cursor/mcp.json.
Actual Behavior
Cursor starts 2 GitHub MCP server Docker containers, leading to:
- Duplicate resource usage
- Potential confusion about which instance is active
- Unnecessary Docker containers running
Steps to Reproduce
- Configure GitHub MCP in
~/.cursor/mcp.jsonwith a singlegithubentry:
{
"mcpServers": {
"github": {
"command": "docker",
"args": [
"run", "-i", "--rm",
"-e", "GITHUB_PERSONAL_ACCESS_TOKEN",
"ghcr.io/github/github-mcp-server"
],
"env": {
"GITHUB_PERSONAL_ACCESS_TOKEN": "${env:GITHUB_PERSONAL_ACCESS_TOKEN}"
}
}
}
}
- Start Cursor
- Check running Docker containers:
docker ps | grep github-mcp-server - Observe 2 containers running instead of 1
Environment
- OS: macOS (darwin 24.6.0)
- Cursor: Latest version
- MCP Configuration: Single GitHub MCP server entry in
~/.cursor/mcp.json - Docker: Running
Additional Context
- This occurs consistently, not intermittently
- Codex (if running) correctly starts only 1 instance
- The issue persists across Cursor restarts
- Only 1 Cursor window/workspace is open
- The
--rmflag should auto-remove containers, but they remain running until manually stopped
Related
Related to issue #3675
This isn't limited to github mcp server unfortunately. I've loaded the mitre-attack mcp server via docker and see 4 instances running in docker. These also remain running even after cursor is terminated.