mcp-server-docker
mcp-server-docker
Control Docker containers, images, and services from your AI coding assistant. List, start, stop, read logs, run commands inside containers, and check resource usage.
npx mcp-docker-serverCompatible with Claude Desktop, Cursor, VS Code Copilot, and any MCP-compatible client. No API keys needed. Connects to your local Docker socket automatically.

Demo built with remotion-readme-kit
왜
If you work with Docker daily, you know the routine: switch to a terminal, type docker ps, scroll through logs, copy container IDs, restart services. It adds up. This MCP server lets your AI assistant handle those tasks for you while you stay focused on code. Ask it to check which containers are running, pull up logs from a failing service, or restart something that got stuck. It talks to Docker's API through the local socket, so there's nothing to configure and no credentials to manage.
Related MCP server: Docker Manager MCP
도구
도구 | 설명 |
| 실행 중(또는 전체) 컨테이너를 상태, 포트, 이미지 정보와 함께 나열합니다. |
| 컨테이너의 최근 로그를 가져옵니다. |
| 중지된 컨테이너를 시작합니다. |
| 실행 중인 컨테이너를 중지합니다. |
| 컨테이너를 다시 시작합니다. |
| 컨테이너를 제거합니다(선택적으로 강제 제거 가능). |
| 실행 중인 컨테이너 내부에서 명령을 실행합니다. |
| 실시간 CPU, 메모리, 네트워크 통계를 가져옵니다. |
| 호스트의 모든 Docker 이미지를 나열합니다. |
| Docker 이미지를 제거합니다. |
빠른 시작
Cursor
.cursor/mcp.json에 추가하세요:
{
"mcpServers": {
"docker": {
"command": "npx",
"args": ["-y", "mcp-docker-server"]
}
}
}Claude Desktop
claude_desktop_config.json에 추가하세요:
{
"mcpServers": {
"docker": {
"command": "npx",
"args": ["-y", "mcp-docker-server"]
}
}
}VS Code
사용자 설정 또는 .vscode/mcp.json에 추가하세요:
{
"mcp": {
"servers": {
"docker": {
"command": "npx",
"args": ["-y", "mcp-docker-server"]
}
}
}
}예시
"실행 중인 모든 Docker 컨테이너 나열"
"nginx 컨테이너의 로그를 보여 줘"
"api-server 컨테이너 다시 시작"
"내 postgres 컨테이너의 CPU 및 메모리 사용량은?"
"web 컨테이너 내부에서
ls -la /app실행""모든 Docker 이미지와 크기 나열"
"이전 이미지를 사용하는 모든 컨테이너 중지"
사전 요구 사항
Docker가 머신에서 실행 중이어야 합니다.
서버는
/var/run/docker.sock(Linux/macOS) 또는 Windows의 named pipe를 통해 Docker 소켓에 연결합니다.API 키나 토큰이 필요 없습니다.
Agent Plugins
이 저장소는 Agent Plugins 1.0.0 패키지입니다. plugin.json, 이식 가능한 mcp.json, skills/가 MCP 서버와 함께 제공됩니다.
Cursor의 경우 저장소를 클론한 다음 ~/.cursor/plugins/local/mcp-server-docker로 복사하거나 심볼릭 링크를 만든 후 창을 다시 로드하세요. Skills와 MCP는 Customize > Plugins 아래에 표시됩니다.
위의 Cursor 및 VS Code 설치 버튼도 여전히 작동합니다. 수동 JSON과 동일한 npx -y mcp-docker-server stdio 서버를 추가합니다.
FAQ
mcp-docker-server란 무엇인가요?
이 MCP 서버의 npm 패키지입니다(저장소 이름 mcp-server-docker). 로컬 Docker 소켓과 통신하여 컨테이너 나열, 로그 추적, 명령 실행, 이미지 관리를 수행합니다.
Docker Desktop을 실행해야 하나요?
네. 데몬이 실행 중이어야 하며 MCP 프로세스가 docker.sock(또는 Windows named pipe)에 도달할 수 있어야 합니다.
프로덕션 컨테이너에 안전한가요?
stop/remove/restart를 파괴적인 작업으로 취급하세요. 프로덕션 워크로드를 변경하기 전에 사용자와 확인하세요.
Cursor에서 Agent Plugin으로 설치할 수 있나요?
네. 번들된 docker-management 스킬이 MCP 구성과 함께 로드되도록 ~/.cursor/plugins/local/mcp-server-docker를 사용하세요.
API 키가 필요한가요?
아니요. 로컬 Docker 액세스만 필요합니다.
개발
git clone https://github.com/ofershap/mcp-server-docker.git
cd mcp-server-docker
npm install
npm test
npm run build참고 항목
제 포트폴리오에서 더 많은 MCP 서버와 개발자 도구를 확인하세요.
저자
README Builder로 작성된 README
라이선스
MIT © 2026 Ofer Shapira
Available Tools
10 toolscontainer_logsC
Get logs from a Docker container.
Inputs: id (required), tail.
container_statsA
Get CPU, memory, and network stats for a running Docker container.
Inputs: id (required).
exec_commandC
Execute a command inside a running Docker container.
Inputs: id (required), command (required).
list_containersB
List Docker containers. Set all=true to include stopped containers.
Inputs: all.
list_imagesB
List Docker images on the host.
Inputs: no named parameters.
remove_containerA
Remove a Docker container. Use force=true to remove running containers.
Inputs: id (required), force.
remove_imageB
Remove a Docker image. Use force=true to force removal.
Inputs: id (required), force.
restart_containerC
Restart a Docker container.
Inputs: id (required).
start_containerA
Start a stopped Docker container.
Inputs: id (required).
stop_containerC
Stop a running Docker container.
Inputs: id (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 10 tools
Each tool has a clearly distinct purpose targeting specific Docker operations: logs, stats, exec, listing containers/images, removal, restart, start, and stop. There is no overlap or ambiguity between tools, as each handles a unique action on a well-defined resource.
All tool names follow a consistent verb_noun pattern with snake_case (e.g., list_containers, remove_image, start_container). The naming is predictable and uniform across all tools, making them easily readable and systematic.
With 10 tools, the server is well-scoped for Docker management, covering essential operations like lifecycle control (start, stop, restart), inspection (logs, stats, list), and cleanup (remove). Each tool earns its place without redundancy or bloat.
The toolset provides strong coverage for core Docker workflows, including CRUD-like operations for containers and images. A minor gap exists in creating or building images (e.g., build_image or pull_image), but agents can still perform most common tasks effectively with the available tools.
Maintenance
Related MCP Connectors
Manage your own cloud with AI: deploy apps, push and ship custom Docker images, manage resources via your AI agent.
Inspect and control your Northflank projects, services, jobs, and builds from your AI assistant.
Read-only Linux server and Docker monitoring for AI assistants: CPU, memory, disk, network.
Create, run and manage Homemade dev VMs and projects from your AI agent.
Related MCP Servers
- AlicenseBqualityDmaintenanceEnables natural language interaction with Docker commands and operations. Supports container management, image operations, system information, and Docker Compose through conversational requests.141MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to manage Docker containers, deploy stacks, and monitor services across multiple Docker hosts from one centralized location. Supports container lifecycle management, Docker Compose operations, and infrastructure orchestration through natural language commands.6MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to manage Docker containers, images, networks, volumes, and Compose services through the Model Context Protocol. It supports system operations, command execution within containers, and integration with Docker Hub and GitHub Container Registry.94 npm2MIT
- AlicenseCqualityDmaintenanceEnables AI assistants to manage Docker containers, images, networks, volumes, and Docker Compose services through the Model Context Protocol.27MIT