Bind patched Penpot MCP into designer + design-reviewer containers #64

Closed
opened 2026-04-18 20:19:17 +00:00 by claude-desktop · 0 comments
Collaborator

User story

As the designer agent, I want the patched Penpot MCP server registered in my container with the right env vars, so that my design-implement skill can actually create pages/frames/shapes on Penpot files instead of aborting with "no mcp__penpot__* namespace".

Context

First live dispatch on #62 failed cleanly — the designer read the spec, listed its MCP surface, found only claude.ai Excalidraw, Context7, Gmail, Google Calendar, Google Drive, Hugging Face, and forgejono mcp__penpot__* — and per the design-implement skill rule ("container env is wrong — surface it, don't silently retry") posted a diagnostic comment and aborted:

  • Failure report: #62 comment #62 (comment)
  • The agent itself behaved correctly; this is infrastructure work that #56's "MCP bindings — container image" AC bullet hasn't covered yet.

The MCP patches already live under ~/Workspace/penpot-mcp-server/ on the claude-hooks host. They include AUTHELIA_BASIC_AUTH (forward-auth), PENPOT_AUTH_TOKEN_COOKIE (pre-seeded OIDC session — this Penpot instance has login-with-password disabled and tokens off), and a DB→RPC fallback on get_file_info. Host secrets are at ~/.config/claude-hooks/{penpot-creds,authelia-creds,penpot-cookie}.

Acceptance criteria

Image

  • claude-hooks:dev (or a new tagged variant for design agents, e.g. claude-hooks:designer) includes the patched penpot-mcp-server binary. Bake-in pattern mirrors the forgejo-mcp patch approach (see commit 109fb12 feat(infra): bake patched forgejo-mcp into the image).
  • Build is reproducible from Dockerfile + /home/charles/Workspace/penpot-mcp-server/ pinned to a known commit (vendor via submodule or copy-on-build).

MCP registration

  • Container's MCP config (the analogue of what registers forgejo-mcp) includes a penpot entry invoking the patched binary with the right env vars.
  • Only designer and design-reviewer containers embed the Penpot MCP. boss/dev/reviewer stay code-only.

Env vars passed from host secrets

  • AUTHELIA_BASIC_AUTH = <user>:<password> from ~/.config/claude-hooks/authelia-creds (format: two lines, user then password).
  • PENPOT_AUTH_TOKEN_COOKIE = contents of ~/.config/claude-hooks/penpot-cookie (single-line JWE).
  • PENPOT_EMAIL, PENPOT_PASSWORD = lines 1+2 of ~/.config/claude-hooks/penpot-creds (even though login-with-password is disabled on our instance, the MCP expects them to be set — empty strings cause an earlier crash per the .env comment).
  • PENPOT_BASE_URL = https://design.jacquin.app, PENPOT_PUBLIC_URL = same.

Smoke

  • New script scripts/smoke-creds.sh (or extend the existing one) also probes Penpot MCP presence inside the designer container — something like docker exec claude-hooks-designer <command> list-tools | grep -c mcp__penpot__ returning > 0.
  • After landing + service restart, re-dispatch on #62 (toggle area:design off/on). The designer task should now drive the MCP, create a Penpot file, and post a handoff comment. The hello-frame with HELLO text is the verification artifact.

Docs

  • CLAUDE.md "Penpot MCP auth" paragraph already mentions the cookie + Authelia-basic bits. Add a pointer to the smoke script and note which containers carry the MCP (and which don't).

Out of scope

  • Token-write RPC in the MCP itself — already covered by #60 (merged in 376f8f9); this ticket is pure plumbing.
  • Upstreaming the penpot-mcp-server patches to the public repo — separate follow-up.
  • Fixing the re-dispatch churn on label_updated (when a second label is added to an already-area:design issue) — noted in fix/forgejo-label-updated-event / PR #63; separate story if the churn bites.

References

  • Failure comment: #62 (comment)
  • Parent story: #56
  • Patched MCP on host: /home/charles/Workspace/penpot-mcp-server/ (see src/penpot_mcp/{config.py,services/api.py,services/changes.py} for the three patches)
  • Host-side secret files: ~/.config/claude-hooks/{penpot-creds,authelia-creds,penpot-cookie} (all 0600)
  • Existing analogue: commit 109fb12 feat(infra): bake patched forgejo-mcp into the image (closes #32) — mirror the pattern
  • Memory: mcp_merge_bug.md — documents the forgejo-mcp patch bake-in

Dependencies

  • Blocked by: nothing (everything needed is already on the host + in main).
  • Blocks: the full #56 designer loop.
  • Branch off: main.
## User story As the **designer agent**, I want the patched Penpot MCP server registered in my container with the right env vars, so that my `design-implement` skill can actually create pages/frames/shapes on Penpot files instead of aborting with "no `mcp__penpot__*` namespace". ## Context First live dispatch on #62 failed cleanly — the designer read the spec, listed its MCP surface, found only `claude.ai Excalidraw`, `Context7`, `Gmail`, `Google Calendar`, `Google Drive`, `Hugging Face`, and `forgejo` — **no `mcp__penpot__*`** — and per the `design-implement` skill rule ("container env is wrong — surface it, don't silently retry") posted a diagnostic comment and aborted: - Failure report: #62 comment https://forge.jacquin.app/charles/claude-hooks/issues/62#issuecomment-5371 - The agent itself behaved correctly; this is infrastructure work that #56's "MCP bindings — container image" AC bullet hasn't covered yet. The MCP patches already live under `~/Workspace/penpot-mcp-server/` on the claude-hooks host. They include `AUTHELIA_BASIC_AUTH` (forward-auth), `PENPOT_AUTH_TOKEN_COOKIE` (pre-seeded OIDC session — this Penpot instance has `login-with-password` disabled and tokens off), and a DB→RPC fallback on `get_file_info`. Host secrets are at `~/.config/claude-hooks/{penpot-creds,authelia-creds,penpot-cookie}`. ## Acceptance criteria ### Image - [ ] `claude-hooks:dev` (or a new tagged variant for design agents, e.g. `claude-hooks:designer`) includes the patched `penpot-mcp-server` binary. Bake-in pattern mirrors the forgejo-mcp patch approach (see commit `109fb12 feat(infra): bake patched forgejo-mcp into the image`). - [ ] Build is reproducible from `Dockerfile` + `/home/charles/Workspace/penpot-mcp-server/` pinned to a known commit (vendor via submodule or copy-on-build). ### MCP registration - [ ] Container's MCP config (the analogue of what registers `forgejo-mcp`) includes a `penpot` entry invoking the patched binary with the right env vars. - [ ] Only `designer` and `design-reviewer` containers embed the Penpot MCP. `boss`/`dev`/`reviewer` stay code-only. ### Env vars passed from host secrets - [ ] `AUTHELIA_BASIC_AUTH` = `<user>:<password>` from `~/.config/claude-hooks/authelia-creds` (format: two lines, `user` then `password`). - [ ] `PENPOT_AUTH_TOKEN_COOKIE` = contents of `~/.config/claude-hooks/penpot-cookie` (single-line JWE). - [ ] `PENPOT_EMAIL`, `PENPOT_PASSWORD` = lines 1+2 of `~/.config/claude-hooks/penpot-creds` (even though login-with-password is disabled on our instance, the MCP expects them to be set — empty strings cause an earlier crash per the `.env` comment). - [ ] `PENPOT_BASE_URL` = `https://design.jacquin.app`, `PENPOT_PUBLIC_URL` = same. ### Smoke - [ ] New script `scripts/smoke-creds.sh` (or extend the existing one) also probes Penpot MCP presence inside the `designer` container — something like `docker exec claude-hooks-designer <command> list-tools | grep -c mcp__penpot__` returning > 0. - [ ] After landing + service restart, re-dispatch on #62 (toggle `area:design` off/on). The designer task should now drive the MCP, create a Penpot file, and post a handoff comment. The `hello-frame` with `HELLO` text is the verification artifact. ### Docs - [ ] `CLAUDE.md` "Penpot MCP auth" paragraph already mentions the cookie + Authelia-basic bits. Add a pointer to the smoke script and note which containers carry the MCP (and which don't). ## Out of scope - Token-write RPC in the MCP itself — already covered by **#60** (merged in `376f8f9`); this ticket is pure plumbing. - Upstreaming the penpot-mcp-server patches to the public repo — separate follow-up. - Fixing the re-dispatch churn on `label_updated` (when a second label is added to an already-`area:design` issue) — noted in `fix/forgejo-label-updated-event` / PR #63; separate story if the churn bites. ## References - Failure comment: https://forge.jacquin.app/charles/claude-hooks/issues/62#issuecomment-5371 - Parent story: #56 - Patched MCP on host: `/home/charles/Workspace/penpot-mcp-server/` (see `src/penpot_mcp/{config.py,services/api.py,services/changes.py}` for the three patches) - Host-side secret files: `~/.config/claude-hooks/{penpot-creds,authelia-creds,penpot-cookie}` (all 0600) - Existing analogue: commit `109fb12 feat(infra): bake patched forgejo-mcp into the image (closes #32)` — mirror the pattern - Memory: `mcp_merge_bug.md` — documents the forgejo-mcp patch bake-in ## Dependencies - **Blocked by:** nothing (everything needed is already on the host + in `main`). - **Blocks:** the full #56 designer loop. - **Branch off:** `main`.
Sign in to join this conversation.
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
charles/claude-hooks#64
No description provided.