Docker Compose
About
Manage Docker containers, volumes, and services using natural language commands.
Details
- Repository
- ckreiling/mcp-server-docker
- License
- GPL-3.0
Explore
- Compose containers with natural language prompts
- Introspect and debug running containers
- Manage persistent data with Docker volumes
- List, create, and remove containers, images, networks, and volumes
- Fetch container logs and resource statistics
- Connect to remote Docker engines over SSH
Setting up with Highlight
This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:
- Download and install Highlight from highlightai.com/download
- Navigate to the plugins tab and select "Add Custom Plugin"
-
Configure the plugin with the settings below
Plugin Name
Docker ComposeCommand (node, npx, python, etc.)uvxArguments-
Argument 1
mcp-server-docker
Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.
-
Argument 1
- Enable "Start Automatically" if you want the plugin to start when Highlight launches
From the repository
Install by adding the server to your Claude Desktop MCP configuration using either uvx mcp-server-docker or a Docker container that mounts the Docker socket. Then invoke tools and prompts through natural language interactions with the LLM.
list_containers
List all containers managed by Docker.
create_container
Create a new container with specified configurations.
run_container
Run a new container based on the specified image.
recreate_container
Recreate a container, stopping and removing the existing one.
start_container
Start a stopped container.
fetch_container_logs
Fetch the logs from a specified container.
stop_container
Stop a running container.
remove_container
Remove a specified container.
list_images
List all images available in Docker.
pull_image
Pull a specified image from a Docker registry.
push_image
Push a specified image to a Docker registry.
build_image
Build a Docker image from a specified Dockerfile.
remove_image
Remove a specified image from Docker.
list_networks
List all networks managed by Docker.
create_network
Create a new network in Docker.
remove_network
Remove a specified network from Docker.
list_volumes
List all volumes managed by Docker.
create_volume
Create a new volume in Docker.
remove_volume
Remove a specified volume from Docker.
Claude Desktop / Cursor
Paste into your MCP client config file to install this server.
{
"mcpServers": {
"docker compose": {
"env": {},
"args": [
"mcp-server-docker"
],
"command": "uvx"
}
}
}
Linux
{
"env": [],
"args": [
"mcp-server-docker"
],
"command": "uvx"
}
Macos
{
"env": [],
"args": [
"mcp-server-docker"
],
"command": "uvx"
}
Windows
{
"env": [],
"args": [
"mcp-server-docker"
],
"command": "uvx"
}
An MCP server for managing Docker with natural language!
- 🚀 Compose containers with natural language
- 🔍 Introspect & debug running containers
- 📀 Manage persistent data with Docker volumes
- Server administrators: connect to remote Docker engines for e.g. managing a public-facing website.
- Tinkerers: run containers locally and experiment with open-source apps supporting Docker.
- AI enthusiasts: push the limits of that an LLM is capable of!
A quick demo showing a WordPress deployment using natural language:
https://github.com/user-attachments/assets/65e35e67-bce0-4449-af7e-9f4dd773b4b3
On MacOS:~/Library/Application\ Support/Claude/claude_desktop_config.json
On Windows:%APPDATA%/Claude/claude_desktop_config.json
If you don't haveuvinstalled, follow the installation instructions for your system:link
Then add the following to your MCP servers file:
"mcpServers": { "mcp-server-docker": { "command": "uvx", "args": [ "mcp-server-docker" ] } }
Purely for convenience, the server can run in a Docker container.
After cloning this repository, build the Docker image:
And then add the following to your MCP servers file:
"mcpServers": { "mcp-server-docker": { "command": "docker", "args": [ "run", "-i", "--rm", "-v", "/var/run/docker.sock:/var/run/docker.sock", "mcp-server-docker:latest" ] } }
Note that we mount the Docker socket as a volume; this ensures the MCP server can connect to and control the local Docker daemon.
Use natural language to compose containers.See abovefor a demo.
Provide a Project Name, and a description of desired containers, and let the LLM do the rest.
This prompt instructs the LLM to enter aplan+applyloop. Your interaction with the LLM will involve the following steps:
- You give the LLM instructions for which containers to bring up
- The LLM calculates a concise natural language plan and presents it to you
- You either:
- Apply the plan
- Provide the LLM feedback, and the LLM recalculates the plan
- name:nginx, containers: "deploy an nginx container exposing it on port 9000"
- name:wordpress, containers: "deploy a WordPress container and a supporting MySQL container, exposing Wordpress on port 9000"
When starting a new chat with this prompt, the LLM will receive the status of any containers, volumes, and networks created with the given projectname.
This is mainly useful for cleaning up, in-case you lose a chat that was responsible for many containers.
The server exposes resource templates rather than enumerating currently-running containers:
- docker://containers/{container_id}/logs(text/plain)
- docker://containers/{container_id}/stats(application/json)
Read either URI with a Docker container ID or name.
- list_containers
- create_container
- run_container
- recreate_container
- start_container
- fetch_container_logs
- stop_container
- remove_container
- list_images
- pull_image
- push_image
- build_image
- remove_image
- list_networks
- create_network
- remove_network
- list_volumes
- create_volume
- remove_volume
DO NOT CONFIGURE CONTAINERS WITH SENSITIVE DATA.This includes API keys, database passwords, etc.
Any sensitive data exchanged with the LLM is inherently compromised, unless the LLM is running on your local machine.
If you are interested in securely passing secrets to containers, file an issue on this repository with your use-case.
Be careful to review the containers that the LLM creates. Docker is not a secure sandbox, and therefore the MCP server can potentially impact the host machine through Docker.
For safety reasons, this MCP server doesn't support sensitive Docker options like--privilegedor--cap-add/--cap-drop. If these features are of interest to you, file an issue on this repository with your use-case.
This server uses the Python Docker SDK'sfrom_envmethod. For configuration details, seethe documentation.
This MCP server can connect to a remote Docker daemon over SSH.
Simply set assh://host URL in the MCP server definition:
"mcpServers": { "mcp-server-docker": { "command": "uvx", "args": [ "mcp-server-docker" ], "env": { "DOCKER_HOST": "ssh://[email protected]" } } }
Prefer using Devbox to configure your development environment. The server uses MCP Python SDK v2's high-levelMCPServerAPI and can be inspected directly:
uv sync --all-groups uv run mcp dev src/mcp_server_docker/server.py:app # or: npx @modelcontextprotocol/inspector uv run mcp-server-docker
Run the hermetic test and lint suite without a Docker daemon:
uv run pytest uv run ruff format --check src tests uv run ruff check src tests
See thedevbox.jsonfor helpful development commands.
After setting up devbox you can configure your Claude MCP config to use it:
"docker": { "command": "/path/to/repo/.devbox/nix/profile/default/bin/uv", "args": [ "--directory", "/path/to/repo/", "run", "mcp-server-docker" ] },
This is a web browser that enables your coding agent, such as Claude Code, to visit websites on your behalf and assist you in identifying bugs or creating UI test cases.
A Ruby implementation of an MCP server for managing and using Docker
A reverse proxy gateway for managing and accessing multiple MCP servers through a single entry point, deployable via Docker.
A Docker-based proxy to access local MCP servers through Claude's web UI using the Remote MCP protocol.
All Azure MCP tools in a single server. The Azure MCP Server implements the MCP specification to create a seamless connection between AI agents and Azure services. Azure MCP Server can be used alone or with the GitHub Copilot for Azure extension in VS Code.
Official Docker MCP Toolkit for discovering, configuring, and running containerized MCP servers through Docker Desktop and the Docker MCP gateway.
The Railway MCP Server enables natural language interaction with your Railway projects and infrastructure. Ask your IDE or AI assistant to create projects, deploy templates, manage environments, pull variables, redeploy services, and more.
The Shipyard CLI provides an MCP server for agents to manage Shipyard environments directly: by pulling logs, comparing branches, running tests, and stopping/starting environments..
Secure virtual machines for agents hosted by Superserve
A secure, Docker-based server providing core execution capabilities for AI agents.
A MCP server for managing Brev development environments using the Brev CLI.
Sign in to leave a review
Use Google, GitHub, or an email account so ratings stay tied to real people.
No reviews posted yet.



