DO

Docker

Created 6 months ago

An MCP server for managing Docker with natural language!

development docker documentation public

What is Docker?

Integrate with Docker to manage containers, images, volumes, and networks.

Documentation

Docker MCP server

An MCP server for managing Docker with natural language!

What can it do?

  • Compose containers with natural language
  • Introspect & debug running containers
  • Manage persistent data with Docker volumes

Who is this for?

  • 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!

Demo

A quick demo showing a WordPress deployment using natural language.

Quickstart# Install\n\n#### Claude Desktop

On MacOS: ~/Library/Application Support/Claude/claude_desktop_config.json On Windows: %APPDATA%/Claude/claude_desktop_config.json

Install from PyPi with uv. If you don't have uv installed, follow the installation instructions for your system.

Then add the following to your MCP servers file:

"mcpServers": {
  "mcp-server-docker": {
    "command": "uvx",
    "args": [ "mcp-server-docker" ]
  }
}

Install with Docker. Purely for convenience, the server can run in a Docker container. After cloning this repository, build the Docker image:

docker build -t mcp-server-docker .

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.

Prompts# docker_compose

Use natural language to compose containers. Provide a Project Name, and a description of desired containers, and let the LLM do the rest.

Resources

The server implements a couple resources for every container:

  • Stats: CPU, memory, etc. for a container
  • Logs: tail some logs from a container

Tools# Containers

  • list_containers
  • create_container
  • run_container
  • recreate_container
  • start_container
  • fetch_container_logs
  • stop_container
  • remove_container

Images

  • list_images
  • pull_image
  • push_image
  • build_image
  • remove_image

Networks

  • list_networks
  • create_network
  • remove_network

Volumes

  • list_volumes
  • create_volume
  • remove_volume

Disclaimers# Sensitive Data

DO NOT CONFIGURE CONTAINERS WITH SENSITIVE DATA.

Reviewing Created Containers

Be careful to review the containers that the LLM creates. Docker is not a secure sandbox.

Configuration

This server uses the Python Docker SDK's from_env method. For configuration details, see the documentation.

Connect to Docker over SSH

This MCP server can connect to a remote Docker daemon over SSH.

Development

Prefer using Devbox to configure your development environment.

Server Config

{
  "mcpServers": {
    "docker-server": {
      "command": "npx",
      "args": [
        "docker"
      ]
    }
  }
}

Links & Status

Repository: github.com
Hosted: No
Global: No
Official: No

Project Info

Hosted Featured
Created At: May 23, 2025
Updated At: Aug 07, 2025
Author: ckreiling
Category: community
License: MIT
Tags:
development docker documentation