
A directory listing describing a cancellation-letter and mailing-address service. The configured public GitHub repository returned 404 during source verification.

A Model Context Protocol server that bridges AI assistants with Docker, enabling natural language Docker operations.
Docker MCP Server is cataloged as an MCP server attributed to swartdraak. A Model Context Protocol server that bridges AI assistants with Docker, enabling natural language Docker operations. It is categorized under developer tools. See the capability inspector for recorded interfaces and their independent review status; consult upstream documentation for the current interface.
Installation configuration is not reviewed. No executable setup is offered for this entry; inspect the source repository before proceeding.
Catalog license label: MIT License. Check the source repository's current license and terms before using, modifying or distributing this software.
能力定义尚未审核。未核验的采集内容不会作为可信接口展示。
暂无可展示的已审核记录。这不表示上游不支持此能力。
暂无可展示的已审核记录。这不表示上游不支持此能力。
暂无可展示的已审核记录。这不表示上游不支持此能力。
Email delivery is not connected. This page does not collect email addresses or create subscriptions.
Browse the registry for current listings instead.
Reviews for Docker MCP Server are not available yet
Review publishing and storage are not connected. This page does not collect or publish ratings or comments, including after sign-in.
Yes. It supports remote Docker hosts over TCP, HTTP, HTTPS, or SSH tunnel and includes TLS/SSL support for secure remote management.
The server handles command, entrypoint, environment variables, and volume bindings as arrays.
Yes, it includes container exec for executing commands in running containers.
README.md · 058eb19b5af7 · 采集于 2026-11-13 08:15:58 UTC
保留上游原文,不做 AI 改写。为安全起见过滤脚本、表单和不安全链接。
当前显示最后一次成功采集的文档快照,请以来源页面为准。
A comprehensive, production-ready, industry-standard compliant MCP (Model Context Protocol) Server that enables full Docker management capabilities for AI assistants like GitHub Copilot and Claude. Featuring 37 powerful tools covering containers, images, networks, volumes, and system operations.
Docker MCP Server is a Model Context Protocol server that bridges AI assistants with Docker, enabling natural language Docker operations. Built with TypeScript and following industry best practices, it provides a complete Docker management solution for AI-powered development workflows.
# Install globally
npm install -g @swartdraak/docker-mcp-server
# Or use with npx (no installation needed)
npx @swartdraak/docker-mcp-server
# Clone the repository
git clone https://github.com/Swartdraak/Docker-MCP.git
cd Docker-MCP
# Install dependencies
npm install
# Build the project
npm run build
# Start the server
npm start
npm install -g @swartdraak/docker-mcp-server
git clone https://github.com/Swartdraak/Docker-MCP.git
cd Docker-MCP
npm install
npm run build
Run the server directly:
npm start
The MCP server supports connecting to remote Docker hosts using environment variables:
DOCKER_HOST=tcp://192.168.1.100:2375 npm start
DOCKER_HOST=https://192.168.1.100:2376 \
DOCKER_TLS_VERIFY=1 \
DOCKER_CERT_PATH=~/.docker/certs \
npm start
First, set up an SSH tunnel:
ssh -NL localhost:2375:/var/run/docker.sock user@remote-host
Then connect to the tunneled Docker:
DOCKER_HOST=tcp://localhost:2375 npm start
To integrate with VS Code and GitHub Copilot, add the following to your MCP settings file:
For Local Docker (~/.vscode/mcp-settings.json or in your workspace settings):
{
"mcpServers": {
"docker": {
"command": "node",
"args": ["/path/to/Docker-MCP/dist/index.js"]
}
}
}
For Remote Docker over TCP:
{
"mcpServers": {
"docker": {
"command": "node",
"args": ["/path/to/Docker-MCP/dist/index.js"],
"env": {
"DOCKER_HOST": "tcp://192.168.1.100:2375"
}
}
}
}
For Remote Docker with TLS:
{
"mcpServers": {
"docker": {
"command": "node",
"args": ["/path/to/Docker-MCP/dist/index.js"],
"env": {
"DOCKER_HOST": "https://192.168.1.100:2376",
"DOCKER_TLS_VERIFY": "1",
"DOCKER_CERT_PATH": "/home/user/.docker/certs"
}
}
}
}
For Claude Desktop (~/Library/Application Support/Claude/claude_desktop_config.json on macOS):
{
"mcpServers": {
"docker": {
"command": "node",
"args": ["/path/to/Docker-MCP/dist/index.js"]
}
}
}
Alternative using npx (after publishing to npm):
{
"mcpServers": {
"docker": {
"command": "npx",
"args": ["@swartdraak/docker-mcp-server"]
}
}
}
Before using the MCP server, you can test your Docker connection with the included test utility:
# Test local Docker connection
node test-connection.js
# Test remote Docker via TCP
DOCKER_HOST=tcp://192.168.1.100:2375 node test-connection.js
# Test remote Docker via TLS
DOCKER_HOST=https://192.168.1.100:2376 \
DOCKER_TLS_VERIFY=1 \
DOCKER_CERT_PATH=~/.docker/certs \
node test-connection.js
# Test SSH tunnel connection
DOCKER_HOST=tcp://localhost:2375 node test-connection.js
The test utility will:
Once the MCP server is running, you can also use the validate_connection tool from your AI assistant:
"Validate my Docker connection"
This tool performs runtime connectivity tests and returns:
You can also test your connection directly with Docker CLI:
# Set environment variables
export DOCKER_HOST=tcp://192.168.1.100:2375
# Test commands
docker version
docker info
docker ps
For detailed setup instructions, troubleshooting, and platform-specific guides, see:
list_containersList all Docker containers (running or all)
{
"all": true
}
create_containerCreate a new Docker container
{
"image": "nginx:latest",
"name": "my-nginx",
"command": ["nginx", "-g", "daemon off;"],
"env": ["NODE_ENV=production"],
"exposedPorts": {"80/tcp": {}},
"hostConfig": {
"PortBindings": {"80/tcp": [{"HostPort": "8080"}]},
"Binds": ["/host/path:/container/path"]
}
}
run_containerCreate and start a container (recommended)
{
"image": "python:3.9",
"name": "my-python-app",
"command": ["python", "app.py"],
"env": ["DEBUG=true", "PORT=5000"]
}
start_containerStart a stopped container
{
"containerId": "container_id_or_name"
}
stop_containerStop a running container
{
"containerId": "container_id_or_name",
"timeout": 10
}
remove_containerRemove a container
{
"containerId": "container_id_or_name",
"force": false,
"volumes": false
}
inspect_containerGet detailed container information
{
"containerId": "container_id_or_name"
}
container_logsGet container logs
{
"containerId": "container_id_or_name",
"tail": 100,
"follow": false
}
exec_container 🆕Execute a command in a running container
{
"containerId": "container_id_or_name",
"command": ["ls", "-la", "/app"],
"workingDir": "/app",
"env": ["DEBUG=true"]
}
container_stats 🆕Get real-time resource usage statistics (CPU, memory, network, I/O)
{
"containerId": "container_id_or_name",
"stream": false
}
restart_container 🆕Restart a Docker container
{
"containerId": "container_id_or_name",
"timeout": 10
}
pause_container 🆕Pause all processes within a container
{
"containerId": "container_id_or_name"
}
unpause_container 🆕Unpause all processes within a container
{
"containerId": "container_id_or_name"
}
rename_container 🆕Rename a Docker container
{
"containerId": "container_id_or_name",
"newName": "new-container-name"
}
prune_containers 🆕Remove all stopped containers
{}
list_imagesList Docker images
{
"all": false
}
pull_imagePull an image from registry
{
"image": "nginx:latest"
}
build_image 🆕Build a Docker image from a Dockerfile
{
"context": "/path/to/build/context",
"dockerfile": "Dockerfile",
"tag": "myimage:latest",
"buildArgs": {
"NODE_VERSION": "18"
}
}
tag_image 🆕Tag an image with a new name/tag
{
"image": "myimage:latest",
"repo": "myrepo/myimage",
"tag": "v1.0.0"
}
push_image 🆕Push an image to a Docker registry
{
"image": "myrepo/myimage:v1.0.0"
}
remove_image 🆕Remove a Docker image
{
"image": "image_id_or_name",
"force": false
}
prune_images 🆕Remove unused images
{
"all": false
}
list_networksList Docker networks
{}
create_network 🆕Create a Docker network
{
"name": "my-network",
"driver": "bridge",
"internal": false
}
inspect_network 🆕Get detailed information about a network
{
"networkId": "network_id_or_name"
}
connect_network 🆕Connect a container to a network
{
"networkId": "network_id_or_name",
"containerId": "container_id_or_name"
}
disconnect_network 🆕Disconnect a container from a network
{
"networkId": "network_id_or_name",
"containerId": "container_id_or_name",
"force": false
}
remove_network 🆕Remove a Docker network
{
"networkId": "network_id_or_name"
}
prune_networks 🆕Remove all unused networks
{}
list_volumesList Docker volumes
{}
create_volume 🆕Create a Docker volume
{
"name": "my-volume",
"driver": "local",
"labels": {
"environment": "production"
}
}
inspect_volume 🆕Get detailed information about a volume
{
"volumeName": "volume_name"
}
remove_volume 🆕Remove a Docker volume
{
"volumeName": "volume_name",
"force": false
}
prune_volumes 🆕Remove all unused volumes
{}
system_info 🆕Get Docker system information
{}
system_version 🆕Get Docker version information
{}
validate_connection 🆕Validate Docker connection and test basic operations. Returns connection status, configuration details, and test results. Useful for troubleshooting connection issues.
{}
This MCP server correctly handles arrays for:
["python", "app.py", "--port", "8000"]["/bin/bash", "-c"]KEY=VALUE strings ["NODE_ENV=production", "PORT=3000"]["/host/path:/container/path"]This resolves the common "array issue" where MCP servers incorrectly expect strings instead of arrays, causing errors when integrated with VS Code and GitHub Copilot.
npm run build - Compile TypeScript to JavaScriptnpm run watch - Watch mode for developmentnpm start - Run the compiled servernpm run dev - Build and runDocker-MCP/
├── src/
│ └── index.ts # Main server implementation
├── dist/ # Compiled JavaScript output
├── package.json # Project dependencies
├── tsconfig.json # TypeScript configuration
└── README.md # This file
If you get "Cannot connect to Docker daemon" errors:
docker pssudo usermod -aG docker $USERIf you can't connect to a remote Docker host:
TCP Connection Issues:
/etc/docker/daemon.jsontelnet remote-host 2375DOCKER_HOST environment variable is set correctlyTLS/HTTPS Connection Issues:
ca.pem, cert.pem, key.pemchmod 644 ca.pem cert.pem key.pemDOCKER_TLS_VERIFY=1 and DOCKER_CERT_PATH are setdocker --tlsverify --host=tcp://remote-host:2376 psSSH Tunnel Issues:
ps aux | grep sshcurl http://localhost:2375/versionlsof -i :2375If the MCP server doesn't appear in VS Code:
dist/index.js is absolutenpm run buildThis server is specifically designed to handle arrays correctly. If you encounter array errors:
command, entrypoint, and env fieldsContributions are welcome! Please feel free to submit a Pull Request.
This project follows industry-standard practices:
git checkout -b feature/my-featurenpm testdevelopFor detailed guidelines, see CONTRIBUTING.md.
main - Production releases (protected)develop - Integration branch (protected)feature/* - New featuresbugfix/* - Bug fixeshotfix/* - Critical production fixesReleases are automated via GitHub Actions when tags are pushed:
# Create release branch
git checkout -b release/2.1.0
# Update version and changelog
npm version minor
# Merge to main and tag
git checkout main
git merge --no-ff release/2.1.0
git tag -a v2.1.0 -m "Version 2.1.0"
git push origin main --tags
See VERSIONING.md for complete release procedures.
For detailed usage examples, see EXAMPLES.md.
For configuration help, see CONFIGURATION.md.
MIT License - see LICENSE file for details
Swartdraak (eternusprocer@gmail.com)
Claim this server with your GitHub account to request manual ownership verification.
Link to the catalog listing for Docker MCP Server from your README. This badge does not certify ownership, compatibility or security.
[](https://awesome-mcp.com/servers/docker-mcp-server)Public repository statistics could not be verified. Check the configured source address; unavailable counts are not zero.
来源、范围和时段分别列出;不相加,不代表安装人数、活跃用户或安全审核。
尚无已审核的包 / 镜像标识,暂不展示下载统计。
Alternative and complementary servers in the same category

A directory listing describing a cancellation-letter and mailing-address service. The configured public GitHub repository returned 404 during source verification.

A hosted MCP service for browsing and searching through Singapore mobile-network proxies.

A directory listing describing a Markdown-to-PDF service. The configured public GitHub repository returned 404 during source verification.