Admin tools for Claude: an MCP server, connected with an admin's approval
- 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:
@@ -71,10 +71,10 @@ jobs:
|
||||
services=$(sh ci/changed-services.sh)
|
||||
echo "changed since the last deployment: ${services:-nothing}"
|
||||
case " $services " in
|
||||
*" backend "*|*" worker "*|*" forum "*|*" horoscope-api "*) ;;
|
||||
*" backend "*|*" worker "*|*" forum "*|*" mcp "*|*" horoscope-api "*) ;;
|
||||
*) echo "no Rust service changed: tests skipped"; exit 0 ;;
|
||||
esac
|
||||
cargo test --locked -p backend -p worker -p forum -p object-storage -p db -p horoscope-client -p service-kit -p analysis-prompt -p email-templates
|
||||
cargo test --locked -p backend -p worker -p forum -p mcp -p object-storage -p db -p horoscope-client -p service-kit -p analysis-prompt -p email-templates
|
||||
|
||||
build:
|
||||
needs: test
|
||||
@@ -127,7 +127,7 @@ jobs:
|
||||
set -eu
|
||||
apk add --no-cache -q curl jq
|
||||
prod=$(git ls-remote origin refs/heads/prod | cut -c1-12)
|
||||
for svc in horoscope-api backend worker forum frontend; do
|
||||
for svc in horoscope-api backend worker forum mcp frontend; do
|
||||
name="sorsfonalak-$svc"
|
||||
page=1
|
||||
: > versions.tsv
|
||||
@@ -152,7 +152,7 @@ jobs:
|
||||
if: always()
|
||||
run: |
|
||||
docker logout "$REGISTRY" || true
|
||||
for svc in horoscope-api backend worker forum frontend; do
|
||||
for svc in horoscope-api backend worker forum mcp frontend; do
|
||||
docker images "$IMAGE_PREFIX-$svc" --format '{{.Repository}}:{{.Tag}}' | xargs -r docker rmi >/dev/null 2>&1 || true
|
||||
done
|
||||
docker image prune -f >/dev/null
|
||||
|
||||
Reference in New Issue
Block a user