What is Docker MCP Server?
A Java-based Model Context Protocol (MCP) server that exposes Docker CLI commands as MCP tools. Built on the MCP Mediator framework, it automatically generates tool definitions from Docker service methods, optionally annotated with @McpTool. Intended for developers and AI agents to manage Docker containers, images, volumes, networks, services, and swarms through MCP-compatible clients like Claude Desktop.
How to use Docker MCP Server?
Run the JAR or native executable with CLI options to set the Docker host, TLS settings, server name, and max connections. For example: java -jar docker-mcp-server.jar --docker-host=tcp://localhost:2376 --server-name=my-server. Then configure an MCP client (e.g., Claude Desktop) to launch the server using java -jar or the native binary, passing the same options.
Key features of Docker MCP Server?
- Automatic generation of MCP tools from Docker service methods
- Supports annotation-free inference for non-annotated methods
- Exposes 50+ Docker commands as individual MCP tools
- Runs as a Java JAR or a standalone GraalVM native image
- Configurable via CLI options and environment variables
- TLS verification support for secure Docker daemon connections
Use cases of Docker MCP Server?
- Let an AI assistant start, stop, or inspect containers via MCP tools
- Automate image builds, pushes, and pulls from a registry
- Manage Docker Swarm nodes, services, and tasks programmatically
- Retrieve container logs, stats, and filesystem changes on demand
コメント