|
1 | 1 | # Docker MCP Server
|
2 | 2 |
|
3 |
| -This module provides a implementation of a Model Context Protocol MCP server for Docker commands using the [`mcp_mediator`](https://github.com/makbn/mcp_mediator) core framework. Docker MCP Servr uses the MCP Mediator automactic MCP Server generation feature to generate MCP Tools for the existing Docker commands using `@@McpTool` and minimal description. |
| 3 | +This module provides a implementation of a Model Context Protocol MCP server for Docker commands using the [`mcp_mediator`](https://github.com/makbn/mcp_mediator) core framework. Docker MCP Servr uses the MCP Mediator automactic MCP Server generation feature to generate MCP Tools for the existing Docker commands using `@McpTool` and minimal description. |
4 | 4 |
|
5 | 5 | Check all the supported commands [here](#supported-docker-commands-as-mcp-server-tools).
|
6 | 6 |
|
@@ -75,24 +75,6 @@ using `java -jar` command. Or, you can create a standalone executable applicatio
|
75 | 75 | and this command creates an executable file: `'mcp-mediator-implementation-docker-[version]` that can be executed.
|
76 | 76 |
|
77 | 77 |
|
78 |
| -### Automatically generate MCP Tools |
79 |
| -As it mentioned before, this project uses [`MCP Mediator`](https://github.com/makbn/mcp_mediator) to generate MCP Tools from the existing Docker Service. In order to create MCP Tool, each method is annotated with `@McpTool` to provide a minimal information about the tool. |
80 |
| -Howeve, this step is not required and MCP Mediator can generate the MCP Tools withot using the `@McpTool` annotation. It generates the name and description automatically using method, class, and package name. |
81 |
| -To enable this feature, you can simply set `create for non-annotated methods` to be true: |
82 |
| -```java |
83 |
| - DefaultMcpMediator mediator = new DefaultMcpMediator(McpMediatorConfigurationBuilder.builder() |
84 |
| - .createDefault() |
85 |
| - .serverName(serverName) |
86 |
| - .serverVersion(serverVersion) |
87 |
| - .build()); |
88 |
| - mediator.registerHandler(McpServiceFactory.create(dockerClientService) |
89 |
| - .createForNonAnnotatedMethods(true) // set to true |
90 |
| -``` |
91 |
| -Keep that in mind, a proper `name` and `description` for MCP Tool can significantly improve the performance of the MCP client to identify and use the tool and generating automatic name and description based on the method, class, and package name can't provide the best peresntation. |
92 |
| -
|
93 |
| -
|
94 |
| -
|
95 |
| -
|
96 | 78 | ### Automatically Generate MCP Tools
|
97 | 79 |
|
98 | 80 | This project integrates with [`MCP Mediator`](https://github.com/makbn/mcp_mediator) to automatically generate MCP Tools from existing Docker services.
|
|
0 commit comments