Docker MCP Toolkit
Code Pathfinder is available on the Docker MCP Catalog — a curated collection of verified MCP servers that run as isolated Docker containers. Install it with one click from Docker Desktop, and it works with every MCP-compatible AI assistant: Claude Code, Cursor, VS Code, Gemini, Codex, Goose, Zed, and more.
No binary installation, no dependency management, no PATH configuration. Docker handles everything.
Prerequisites
- Docker Desktop 4.48 or later
- MCP Toolkit enabled in Docker Desktop (Settings → Beta features → Enable Docker MCP Toolkit)
Setup
The easiest way is through the Docker Desktop UI: open MCP Toolkit → Catalog, search for Code Pathfinder, add it to a profile, configure the project path, and connect your AI client from the Clients tab.
For CLI setup, follow the steps below. The commands differ slightly depending on your Docker Desktop version.
Step 1: Enable the server
Docker Desktop 4.62+ (profile-based CLI):
docker mcp profile server add my-profile \
--server catalog://mcp/docker-mcp-catalog/code-pathfinderDocker Desktop 4.48–4.61:
docker mcp server enable code-pathfinderStep 2: Configure your project path
Code Pathfinder needs to know which project directory to analyze.
Docker Desktop 4.62+:
docker mcp profile config my-profile \
--set code-pathfinder.path=/absolute/path/to/your/projectDocker Desktop 4.48–4.61:
cat > ~/.docker/mcp/config.yaml << EOF
code-pathfinder:
path: /absolute/path/to/your/project
EOFStep 3: Connect your AI assistant
From the Clients tab in Docker Desktop MCP Toolkit, click Connect next to your AI assistant. Or use the CLI:
Docker Desktop 4.62+:
docker mcp client connect claude-code --profile my-profile
docker mcp client connect cursor --profile my-profile
docker mcp client connect vscode --profile my-profile
docker mcp client connect gemini --profile my-profileDocker Desktop 4.48–4.61:
docker mcp client connect claude-code
docker mcp client connect cursor
docker mcp client connect vscode
docker mcp client connect geminiThis creates an MCP_DOCKER entry in your assistant's MCP configuration that routes all tool calls through the Docker MCP Gateway.
Supported clients: claude-code, claude-desktop, cline, codex, continue, cursor, gemini, goose, kiro, lmstudio, opencode, sema4, vscode, zed.
Step 4: Verify the connection
Claude Code:
claude mcp list
# Should show: MCP_DOCKER: docker mcp gateway run - ✓ ConnectedGemini:
gemini mcp list
# Should show: ✓ MCP_DOCKER: docker mcp gateway run (stdio) - ConnectedCodex:
codex mcp list
# Should show: MCP_DOCKER with "enabled" statusAvailable Tools
Code Pathfinder exposes 12 MCP tools through Docker MCP Toolkit:
Code Intelligence (8 tools)
| Tool | Description |
|---|---|
get_index_info | Codebase statistics — symbols, modules, call edges, files. Use first. |
find_symbol | Search functions, classes, methods by name/type/module. Partial matching. |
find_module | Search Python modules by name. Returns file path and symbol counts. |
list_modules | List all Python modules in the indexed project. |
get_callers | Reverse call graph — who calls this function? |
get_callees | Forward call graph — what does this function call? |
get_call_details | Detailed call site info between two specific functions. |
resolve_import | Resolve Python import paths to file locations. |
Docker Analysis (4 tools)
| Tool | Description |
|---|---|
find_dockerfile_instructions | Search Dockerfile instructions with semantic filters (base image, ports, digest pinning). |
find_compose_services | Search docker-compose services (privileged mode, volumes, ports). |
get_dockerfile_details | Full Dockerfile breakdown with multi-stage build analysis. |
get_docker_dependencies | Dependency graph for compose services and Dockerfile stages. |
Supported Languages
- Python — Full call graph, type inference, stdlib/third-party resolution
- Java — Method invocations, class hierarchy, annotations
- Go — Function declarations, struct methods, stdlib metadata
- Dockerfile — Instruction parsing, multi-stage analysis, base image tracking
- docker-compose — Service configuration, dependency mapping
Example Prompts
Once connected, try these in your AI assistant. Each prompt maps to a specific Code Pathfinder tool:
- Use get_index_info to show me the codebase stats
- Use find_symbol to find all class definitions in the project
- Use get_callers to show who calls the process_payment function
- Use get_callees to show what the login_endpoint function depends on
- Use find_symbol to list all methods in the auth module
- Use find_dockerfile_instructions to find all Dockerfiles with unpinned base images
- Use find_compose_services to show docker-compose services running in privileged mode
- Use get_dockerfile_details to analyze the main Dockerfile
How It Works
When you invoke a tool, the Docker MCP Gateway:
- Starts the Code Pathfinder container with your project directory mounted at
/project - The server indexes your codebase (typically 5-30 seconds depending on size)
- Tool calls are routed over stdio (JSON-RPC 2.0) to the running container
- Results are returned to your AI assistant
The container runs as a non-root user with restricted privileges. Network access is limited to:
assets.codepathfinder.dev— type registry data (stdlib and third-party library signatures for better type inference)us.i.posthog.com— anonymous usage analytics (can be disabled)
Switching Projects
To analyze a different project, update the config:
cat > ~/.docker/mcp/config.yaml << EOF
code-pathfinder:
path: /path/to/different/project
EOFThe next tool call will start a fresh container indexing the new project.
Manual Docker Usage
If you prefer to run the container directly without Docker Desktop MCP Toolkit:
# Add to Claude Code
claude mcp add -s user code-pathfinder \
-- docker run -i --rm \
-v /path/to/your/project:/project \
mcp/code-pathfinder:latest
# Verify
claude mcp listOr add to any MCP client's JSON config:
{
"mcpServers": {
"code-pathfinder": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-v",
"/path/to/your/project:/project",
"mcp/code-pathfinder:latest"
]
}
}
}Disabling Analytics
Code Pathfinder collects anonymous usage analytics (tool call counts, indexing time, language stats) to improve the product. No code, file paths, or personally identifiable information is ever sent.
To disable analytics when using Docker MCP Toolkit, run the container with the --disable-metrics flag. For manual Docker usage:
claude mcp add -s user code-pathfinder \
-- docker run -i --rm \
-v /path/to/your/project:/project \
mcp/code-pathfinder:latest --disable-metricsFor the JSON config approach, append "--disable-metrics" to the args array:
{
"mcpServers": {
"code-pathfinder": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-v",
"/path/to/your/project:/project",
"mcp/code-pathfinder:latest",
"--disable-metrics"
]
}
}
}Troubleshooting
Tools not showing up
Make sure the server is enabled and configured:
# Docker Desktop 4.62+
docker mcp profile server ls --filter profile=my-profile
# Docker Desktop 4.48–4.61
docker mcp server ls # Should show code-pathfinder
docker mcp tools ls # Should list 12 Code Pathfinder tools"Indexing" response on first call
This is normal. The server indexes your codebase in the background when the container starts. Small projects take 10-30 seconds, larger codebases may take a few minutes. Subsequent calls are instant once indexing completes.
Permission errors on mounted volume
The container runs as a non-root user. Ensure the project directory is readable:
ls -la /path/to/your/project # Check permissionsNext Steps
MCP Tools Reference →
Detailed documentation for all 12 tools: code intelligence, call graph traversal, Docker analysis, and more
Install from CLI →
Install Code Pathfinder via Homebrew, pip, or download — no Docker required
Configuration Guide →
Advanced options: HTTP transport, custom Python versions, multi-project setups