cursor icon indicating copy to clipboard operation
cursor copied to clipboard

Cursor starts duplicate GitHub MCP server instances

Open Damith88 opened this issue 3 months ago • 1 comments

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

  1. Configure GitHub MCP in ~/.cursor/mcp.json with a single github entry:
{
  "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}"
      }
    }
  }
}
  1. Start Cursor
  2. Check running Docker containers: docker ps | grep github-mcp-server
  3. 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 --rm flag should auto-remove containers, but they remain running until manually stopped

Related

Related to issue #3675

Damith88 avatar Nov 04 '25 12:11 Damith88

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.

zestysoft avatar Nov 11 '25 07:11 zestysoft