原型 · 预览版:收录官方注册中心里的全部服务器,每 30 分钟同步一次。评价和账户功能将在后续阶段推出。
PopNx MCP为使用 AI 的人准备的 MCP 服务器 · 用大白话讲清楚

Docker MCP Server

作者:hypnosis版本 2.0.1i★ –i在你的电脑上运行
注册名称io.github.hypnosis/docker-mcp-server

安装

概览

作者提供的说明(英文原文)

Docker for AI agents — containers, compose stacks, logs and databases, locally or over SSH.

PopNx MCP 的三大支柱

这三项永远不会合并成一个分数:意见、测量和人气是不同的东西。

它能帮你做什么

我们还没有为它写通俗的介绍。下面是我们从注册中心读取到的事实。

  • 连接方式: 在你的电脑上运行
  • 传输方式: stdio
  • 分类: 开发者工具

安装

选择你使用的 AI 应用,然后复制设置。

安装之前

  • 基础检查:1 项中通过 1 项
  • 在你的电脑上运行,拥有你的用户账户的权限(文件、网络、应用)。
  • 需要你自己填写: DOCKER_MCP_PROFILES_FILE, DOCKER_PROFILES, DOCKER_MCP_ALLOW_SSH_FALLBACK, LOG_LEVEL

你需要

  • npm已安装 Node.js(用于 npx 命令)

你用的是哪个应用?

在上方选择你的应用。我们会记住它,下次按钮会显示“安装到 …”。

打开 Claude Desktop → Settings → Developer → Edit Config,把下面的内容粘贴到 claude_desktop_config.json

{
  "mcpServers": {
    "docker": {
      "command": "npx",
      "args": [
        "-y",
        "@hypnosis/docker-mcp-server"
      ],
      "env": {
        "DOCKER_MCP_PROFILES_FILE": "your-value",
        "DOCKER_PROFILES": "your-value",
        "DOCKER_MCP_ALLOW_SSH_FALLBACK": "your-value",
        "LOG_LEVEL": "your-value"
      }
    }
  }
}

在终端中运行这条命令

claude mcp add docker --env DOCKER_MCP_PROFILES_FILE=your-value --env DOCKER_PROFILES=your-value --env DOCKER_MCP_ALLOW_SSH_FALLBACK=your-value --env LOG_LEVEL=your-value -- npx -y @hypnosis/docker-mcp-server

运行前请先填写空着的值。

在 Cursor 中打开

或者自己复制设置

粘贴到项目中的 .cursor/mcp.json,或 ~/.cursor/mcp.json

{
  "mcpServers": {
    "docker": {
      "command": "npx",
      "args": [
        "-y",
        "@hypnosis/docker-mcp-server"
      ],
      "env": {
        "DOCKER_MCP_PROFILES_FILE": "your-value",
        "DOCKER_PROFILES": "your-value",
        "DOCKER_MCP_ALLOW_SSH_FALLBACK": "your-value",
        "LOG_LEVEL": "your-value"
      }
    }
  }
}

浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。

在 VS Code 中打开

或者自己复制设置

粘贴到项目中的 .vscode/mcp.json

{
  "servers": {
    "docker": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@hypnosis/docker-mcp-server"
      ],
      "env": {
        "DOCKER_MCP_PROFILES_FILE": "your-value",
        "DOCKER_PROFILES": "your-value",
        "DOCKER_MCP_ALLOW_SSH_FALLBACK": "your-value",
        "LOG_LEVEL": "your-value"
      }
    }
  }
}

浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。

这个服务器在你的电脑上运行,而 ChatGPT 只能连接互联网上的服务器。请选择其他应用。

你的选择通过 Cookie 保存在这台设备上,无需账户。

需要你填写的值

  • DOCKER_MCP_PROFILES_FILE env
    Absolute path to the JSON file describing the Docker hosts this agent may reach. Without it the server answers about the Docker on this machine.
  • DOCKER_PROFILES env
    The same profiles JSON inline, used when no profiles file is set.
  • DOCKER_MCP_ALLOW_SSH_FALLBACK env
    Keep going when a profile's SSH key is missing, instead of refusing the profile. Defaults to false.
  • LOG_LEVEL env
    Log verbosity: error, warn, info or debug. Defaults to info.

这些设置是根据作者在注册中心的条目生成的。如果 README 的写法不同,请以 README 为准。

它能做什么

它在你的电脑上运行;安装后,工具列表会显示在你的 AI 应用中。

基础检查i

我们检查的是任何人都能看到的信息;我们没有阅读代码。不适用的检查项不计入总数。 · 检查于 2026年11月6日

  • ✓ 通过

    作者与仓库一致

    注册名称已通过 GitHub 账户 hypnosis 验证,该账户拥有此仓库

  • … 尚未检查

    仍在维护

    我们还没有从 GitHub 读取这个仓库

  • … 尚未检查

    有许可证

    我们还没有从 GitHub 读取这个仓库

  • – 不适用

    端点有响应

    它在你的电脑上运行,没有互联网端点

  • – 不适用

    使用 OAuth 登录

    在你的电脑上运行,改用本地设置

  • … 尚未检查

    工具描述中没有隐藏指令

    它在你的电脑上运行;我们只能读取互联网端点的工具列表

与“开发者工具”中的其他服务器比较i

  • 星标数多于此分类中其他 1389 个服务器的 0%
  • 发布到注册中心的时间比此分类中其他 1389 个服务器的 45% 更新
  • 基础检查结果等于或优于此分类中其他 1389 个服务器的 100%

与注册中心里这个分类中所有活跃的服务器比较。只有当发布者拥有该仓库时,星标数才计入。

常见问题

Docker MCP Server 安全吗?

它在 1 项适用的基础检查中通过了 1 项。我们没有阅读代码。在添加密钥或令牌之前,请先看看这个服务器要求哪些权限,并使用只具备所需权限的密钥。

它需要哪些密钥或代码?

注册中心没有列出必需的密钥,不过有些服务器会在首次使用时要求你登录。

它在我的电脑上运行还是在云端?

它在你的电脑上运行。你的 AI 应用会在需要时启动它,数据不会经过作者的服务器(除非它自己调用在线服务)。

它还在维护吗?

GitHub 仓库最后更新于–,最新版本(2.0.1)于2个月前进入注册中心。

哪些应用可以使用它?

支持 MCP 的应用,例如 Claude Desktop、Claude Code、Cursor 和 VS Code。你的电脑上还需要有 Node.js。

有什么可以替代它?

同一分类中有:GitHub, Desktop Commander, Cloudflare MCP

替代选择

同一分类中其他作者的服务器,按星标数排序。

如何看卡片:★ GitHub 星标i三大支柱:评价 · 检查 · 使用情况i更新 = 最新版本发布到注册中心的时间i

GitHub

作者:github

Connect AI assistants to GitHub - manage repos, issues, PRs, and workflows through natural language.

电脑或云端★ 34,245MIT3天前更新
安装

Desktop Commander

作者:wonderwhy-er

MCP server for terminal commands, file operations, and process management

在你的电脑上运行★ 10,225MIT15天前更新
安装

Cloudflare MCP

作者:cloudflare

Cloudflare MCP servers

在云端运行★ 4,446Apache-2.014个月前更新
安装

作者的 README

打开 README

按原文从作者的仓库复制。PopNx MCP 没有审查或背书其内容。HTML、图片和脚本已被移除。链接会离开本站。

Docker MCP Server — Docker tools for AI agents

A Docker MCP server that lets AI agents operate Compose stacks with structured, Docker-native tools — instead of brittle shell commands and terminal-shaped output.

Inspect containers, read logs, check health, query databases, take dumps, and bring stacks up or down — on your laptop or on a server across the world by naming its profile.

It speaks Docker the way you do: your compose files, project names, and service names. Answers come back as named fields with enough context for an agent to act on them, rather than parse an ASCII table and guess.

Works with Claude Code, Codex CLI, Cursor, opencode, Gemini CLI, Qwen Code and other MCP clients.

[Install](#install-in-30-seconds) · [Tools](#docker-mcp-tools-for-containers-compose-and-databases) · [Setup](#set-up-the-docker-mcp-server) · [Security](#destructive-command-protection-for-ai-agents) · [Docs](docs/tools.md) · [Changelog](CHANGELOG.md)


Install in 30 seconds

No global installation required. npx downloads the package on first use:

npx -y @hypnosis/docker-mcp-server

Add it to your MCP client — Claude Code, for example — for every project:

claude mcp add docker -s user -- npx -y @hypnosis/docker-mcp-server

That is the whole setup for the Docker on this machine. No profiles file, no environment variables: the server uses the local Docker socket, and the compose project of your working directory is the project it answers about.

For a Docker host on another machine, add one file with the servers you reach over SSH:

claude mcp add docker -s user \

-e DOCKER_MCP_PROFILES_FILE="$HOME/.claude/docker-profiles.json" \ -- npx -y @hypnosis/docker-mcp-server

{

"default": "local", "profiles": { "local": { "mode": "local" }, "production": { "host": "prod.example.com", "username": "deployer", "privateKeyPath": "~/.ssh/id_ed25519" } } }

Now every tool takes a profile, and docker_health({ action: "profiles" }) lists what the server was given.

Codex, Cursor, opencode and other clients are covered in Set up the Docker MCP server.

Install as a plugin

Some clients — Claude Code, for example — can take the whole thing as a plugin instead:

/plugin marketplace add hypnosis/docker-mcp-server

/plugin install docker-mcp-server@docker-mcp-server

The plugin brings the server up against the Docker on this machine, with no configuration at all. Point it at other hosts the same way as above, with DOCKER_MCP_PROFILES_FILE.

Requirements

Node.js 18+ and a Docker daemon you can already reach — the local socket, or a remote host over SSH with a key.

The server starts whether or not Docker is up. A call made while the daemon is down answers "start Docker" and works on the next try, without restarting your MCP client.

Prefer a pinned version, offline work, or one less registry check per launch: npm install -g @hypnosis/docker-mcp-server, then use docker-mcp-server as the command instead of npx.

Who this Docker MCP server is for

  • AI-assisted developers who build, run, and debug applications with Docker Compose.
  • Backend and full-stack developers who need their coding agent to inspect containers, logs, health checks, databases, and Compose services while solving a problem.
  • Independent developers and small product teams who deploy Docker applications to their own servers and want one agent workflow for local development and production.
  • Platform engineers who maintain Docker environments across development, staging, and production hosts.
  • DevOps engineers and SREs using AI coding agents for incident checks, routine container work, and faster investigation of Compose-based services.
  • Agencies and technical teams maintaining client applications, where an agent needs to understand an unfamiliar Compose stack before making a change.
  • QA and release engineers who need repeatable visibility into test stacks, service health, logs, and databases before a release.

Why use a Docker MCP server instead of raw Docker CLI?

Docker CLI is excellent for a person at a terminal. An AI agent needs something different: Docker and Compose concepts it can query directly, results it can reason about, and clear boundaries between what happened, what was not found, and what could not be checked.

Less context, lower AI cost

docker ps, docker stats, and docker logs are designed to be read on a screen. Their output mixes labels, values, units, and formatting into text an agent must parse before it can use it.

A Docker MCP tool returns the fields the task needs: service, project, state, health, ports, timestamps, byte counts, exit codes, and log streams. The agent receives less terminal noise, spends fewer tokens interpreting it, and keeps more context for the problem it is solving.

Debug Docker Compose as a system

A Docker application is more than a list of containers. It is a Compose project with services, dependencies, health checks, logs, databases, and resources that affect one another.

The server lets an agent ask about that system in the names you use every day: the project, service, and Compose file. One call can show the state and health of a stack; another can inspect a bounded log window, measure a service, or query the database already running beside it. The agent spends its turns finding the cause, not assembling and decoding shell commands.

Make decisions from explicit results

A shell command can return an empty table, clipped output, or an error printed alongside ordinary text. For an agent, those are different situations — and treating them as the same leads to guesses.

Docker MCP results say what was found, what was not found, what was cut short, and why an action did not run. A missing healthcheck is not a failed healthcheck; an empty list is not a failed read; a command with no exit code never started. That gives the agent a reliable basis for its next step, and gives you fewer confident-looking but wrong fixes.

Manage local and remote Docker hosts over SSH

Use the same Docker MCP tools on the Docker daemon beside you and on a remote server. A remote Docker host is a profile: a stable name, its SSH connection, and the authentication it needs. The agent names that profile in a tool call:

docker_container({ "action": "list", "profile": "production" })

Leave profile out and the default Docker host answers, so local development stays frictionless. Name a profile the server does not know and the response lists the profiles it does know instead of quietly sending a request to another machine.

Remote Docker Compose projects are resolved by the labels their containers already carry. Ask for a project by name wherever it lives on that host — no remote working directory or fixed Compose path to maintain. For a project that has not run there yet, pass its file explicitly with compose_path.

Built for the Model Context Protocol

A native Docker MCP server built on the official MCP SDK, with structured tools designed for AI agents rather than terminal automation.

Its behaviour is covered by unit tests and end-to-end tests that run against real Docker containers, not only mocks.


Docker MCP vs Docker CLI: practical examples

The Docker CLI is the right interface when a person is driving the terminal. These examples show what changes when an AI agent needs to inspect a Docker Compose application, understand the result, and choose the next safe step.

Each comparison uses the same real-world task: first the commands and output an agent would have to work through, then the structured Docker MCP result it can use directly.

Diagnose the health of a Docker Compose stack

Situation: A deploy just went out. The site is slow, and you do not know whether a

container is down, a healthcheck is failing, or something is eating the memory.

Question: "Is this stack healthy?"

Raw docker CLI
$ docker compose ps

NAME IMAGE STATUS PORTS shop-api-1 shop-api:latest Up 4 minutes (healthy) 0.0.0.0:8080->8080/tcp shop-postgres-1 postgres:16 Up 4 minutes (unhealthy) 5432/tcp shop-worker-1 shop-worker:latest Exited (1) 2 minutes ago $ docker stats --no-stream CONTAINER ID NAME CPU % MEM USAGE / LIMIT MEM % NET I/O BLOCK I/O 1f2c4d5e6a7b shop-api-1 3.10% 214.8MiB / 7.66GiB 2.74% 12.4MB / 8.9MB 0B / 4.1MB 9a8b7c6d5e4f shop-postgres-1 0.42% 1.204GiB / 7.66GiB 15.7% 3.2MB / 44MB 112MB / 890MB $ docker inspect --format '{{.State.Health.Status}}' shop-postgres-1 unhealthy $ docker inspect --format '{{.State.Health.Status}}' shop-worker-1 Template parsing error: executing "" at <.State.Health.Status>: nil pointer evaluating *types.Health.Status

Three commands, three formats, and the last one fails because the worker image declares no healthcheck at all. Nothing is broken — there is simply nothing to read — but the agent now has to tell "no healthcheck" apart from "failing", and a table gives it no help.

Structured MCP result
docker_container({ "action": "list", "project": "shop" })
{

"action": "list", "project": "shop", "containers": [ { "name": "shop-api-1", "service": "api", "project": "shop", "state": "running", "health": "healthy", "image": "shop-api:latest", "ports": ["0.0.0.0:8080->8080/tcp"], "created": "2026-08-24T09:14:02Z" }, { "name": "shop-postgres-1", "service": "postgres", "project": "shop", "state": "running", "health": "unhealthy", "image": "postgres:16", "ports": ["5432/tcp"], "created": "2026-08-24T09:14:01Z" }, { "name": "shop-worker-1", "service": "worker", "project": "shop", "state": "exited", "health": null, "image": "shop-worker:latest", "ports": [], "created": "2026-08-24T09:14:01Z" } ], "reason": null, "legend": { "containers[].state=running": "Running now.", "containers[]

只显示了开头部分;其余内容请在仓库中阅读

问 PopNx