From 2908b2dfdbd54fd7e9b03d852776cd5edb3e2046 Mon Sep 17 00:00:00 2001 From: MaxonT <173550318+MaxonT@users.noreply.github.com> Date: Mon, 16 Nov 2026 18:27:52 -0600 Subject: [PATCH] docker: start the MCP server by default and install the mcp extra The image ran `aisync --help` and installed without the mcp extra, so a host that launches the container with no arguments and speaks MCP over stdio (Glama build and score) got an exit code of 2 and "the MCP server needs the official SDK". Install .[mcp] and make `mcp` the default command. CLI use still works: `docker run --rm ghcr.io/maxont/aisync --help`. Verified: docker build from this Dockerfile succeeds; the default run answers initialize and tools/list over stdio; `--version` prints aisync 0.2.10. Co-authored-by: MaxonT <173550318+MaxonT@users.noreply.github.com> Agent: claude-code --- Dockerfile | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 94cab83..5ea53b0 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,9 @@ # What: container image for aisync, published to ghcr.io by the release workflow. # Why: GitHub Packages does not host Python packages, so the image is the package. -# How: docker run --rm ghcr.io/maxont/aisync --help +# Glama (and any MCP host) launches the image with no arguments and talks MCP over stdio, +# so the default command is the MCP server, and the mcp extra must be installed for it to start. +# How: docker run --rm -i ghcr.io/maxont/aisync (MCP server over stdio) +# docker run --rm ghcr.io/maxont/aisync --help (CLI) FROM python:3.12-slim LABEL org.opencontainers.image.source="https://github.com/MaxonT/aisync" \ org.opencontainers.image.description="Advanced context management for all your AI coding tools: shared rules, a hash-chained journal, file claims and mid-session news hooks for Claude Code, Codex and Cursor." \ @@ -8,7 +11,8 @@ LABEL org.opencontainers.image.source="https://github.com/MaxonT/aisync" \ WORKDIR /src COPY pyproject.toml README.md LICENSE ./ COPY ai_sync ./ai_sync -RUN pip install --no-cache-dir . && rm -rf /src +RUN pip install --no-cache-dir ".[mcp]" && rm -rf /src WORKDIR /data +ENV NO_STAR_PROMPT=1 ENTRYPOINT ["aisync"] -CMD ["--help"] +CMD ["mcp"]