Admin tools for Claude: an MCP server, connected with an admin's approval
CI / build (push) Skipped
CI / deploy (push) Skipped
CI / test (push) Successful in 4m27s

- services/mcp: the MCP server at /mcp (Streamable HTTP, stateless): the
  admin's reading tools, the daily tasks and the forum's moderation; every
  tool calls the site's API with the caller's token, and members' e-mail
  addresses and names are masked in the answers.
- Backend: OAuth 2.1 for MCP clients (registration with Claude's or a local
  return address only, PKCE, rotating refresh tokens, revocation); the admin
  guards accept the token for reading and the writes in MCP_WRITES only.
- Forum: an admin's token reaches the moderator endpoints only.
- Frontend: the approval page (/oauth/engedely), Admin → Claude to revoke a
  connection, the authorization server's metadata at its standard address.
- Deploy: the mcp service in compose, Caddy, CI; the worker removes old
  codes, tokens and clients. docs/mcp.md.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012vLHzh5qUhFtmJhzkcTbXL
This commit is contained in:
feco
2026-11-27 17:09:14 +00:00
co-authored by Claude Opus 5.5
parent 08ad7b0a79
commit 2c63384606
40 changed files with 3695 additions and 49 deletions
+20
View File
@@ -75,6 +75,8 @@ services:
S3_BUCKET: ${S3_BUCKET:-}
S3_REGION: ${S3_REGION:-us-east-1}
S3_CREATE_BUCKET: ${S3_CREATE_BUCKET:-false}
# The MCP server's address, the audience of its tokens (docs/mcp.md).
MCP_RESOURCE_URL: ${MCP_RESOURCE_URL:-http://localhost:8084/mcp}
# STRIPE_SECRET_KEY / STRIPE_WEBHOOK_SECRET (test keys; docs/fizetes.md).
# With them Stripe replaces the stand-in payment.
env_file:
@@ -165,5 +167,23 @@ services:
- /tmp
restart: unless-stopped
# The admin tools for Claude (docs/mcp.md): connect Claude Code to
# http://localhost:8084/mcp; the login and approval happen on the frontend.
mcp:
build:
context: .
dockerfile: services/mcp/Dockerfile
image: sorsfonalak/mcp:latest
ports:
- "8084:8084"
environment:
API_URL: http://frontend:3000/api/v1
PUBLIC_BASE_URL: ${PUBLIC_BASE_URL:-http://localhost:3001}
MCP_PUBLIC_URL: ${MCP_RESOURCE_URL:-http://localhost:8084/mcp}
depends_on:
- frontend
read_only: true
restart: unless-stopped
volumes:
pgdata: