MCP client times out when launching Docker MCP Toolkit gateway (full catalog, Windows)

Resolved 💬 3 comments Opened Oct 21, 2025 by WHA-Dev Closed Oct 21, 2025
💡 Likely answer: A maintainer (github-actions[bot], contributor) responded on this thread — see the highlighted reply below.

Summary

Codex CLI (0.47.0) fails to attach to Docker’s MCP Toolkit when the gateway
is launched with the full Docker catalog. Codex spawns docker mcp gateway run
via stdio, but the MCP handshake never completes: the CLI waits for a JSON-
RPC response that never arrives and exits after ~1 s with “MCP client for
MCP_DOCKER failed to start: request timed out”. The gateway itself finishes
initialisation (~1.7 s) and prints “Start stdio server”, so the process is
healthy—the timeout happens on Codex’s side.

Environment

  • Codex CLI: codex --version → 0.47.0 (on Windows 11, PowerShell)
  • Docker Desktop: (include your version if you have it handy)
  • Docker MCP Toolkit CLI (bundled with Docker Desktop)
  • Codex config entry:

[mcp_servers.MCP_DOCKER]
command = "docker"
args = ["mcp", "gateway", "run"]

Steps to reproduce

  1. Ensure Docker Desktop’s MCP catalog is fresh (default registry.yaml with

all servers enabled).

  1. Open one PowerShell terminal and run:

tools.

Actual behaviour

Codex tears the connection down after roughly one second:

■ MCP client for MCP_DOCKER failed to start: request timed out

Relevant log excerpt from C:\Users\<user>\.codex\log\codex-tui.log:

2025-10-21T09:53:10.916906Z INFO aggregated 0 tools from 0 servers
2025-10-21T09:53:10.916945Z ERROR MCP client for MCP_DOCKER failed to
start: request timed out

Meanwhile the gateway that Codex launched reports:

  • Watching for configuration updates...

> Initialized in 1.7119549s
> Start stdio server

Additional notes

  • If I manually run docker mcp gateway run beforehand, it reaches “Start

stdio server” in ~1.7 s (with images cached). Codex still times out when it
launches another instance itself.

fails earlier with 405 Method Not Allowed because the Docker gateway only
allows GET on /sse; the Codex client POSTs the handshake payload. So the
stdio path is the only available option.

  • Reducing the enabled servers (e.g. only time, memory, SQLite) makes the

handshake succeed—suggesting Codex’s timeout is simply too aggressive for
the full catalog initialisation.

Please let me know if you need the entire log file or a recording; happy to
provide any extra diagnostics.

View original on GitHub ↗

3 Comments

WHA-Dev · 10 months ago

thread ID 019a05fa-41a5-73b0-9893-f92686561b06

github-actions[bot] contributor · 10 months ago

Potential duplicates detected. Please review them and close your issue if it is a duplicate.

  • #3408
  • #4400

Powered by Codex Action

gpeal contributor · 10 months ago