StarPunk: MCP sidecar and /mcp routing (v2.15.0)
Add the starpunk-mcp container (same image, uvicorn :8001, shared env via anchor, BACKGROUND_WORKERS_ENABLED=false, socket healthcheck) and route /mcp and /.well-known/oauth-protected-resource to it in Caddy. Bump starpunk_version to v2.15.0 (needs the v2.15.0 tag built first). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
1cbfa29654
commit
808c177b02
3 files changed
+39
-4
No files matched your search
@@ -116,8 +116,15 @@ pdg.thesatelliteoflove.com {
|
||||
|
||||
starpunk.thesatelliteoflove.com {
|
||||
import hsts
|
||||
reverse_proxy starpunk:8000
|
||||
}
|
||||
# MCP endpoint and its OAuth protected resource metadata (StarPunk v2.15.0)
|
||||
@mcp path /mcp /mcp/* /.well-known/oauth-protected-resource /.well-known/oauth-protected-resource/*
|
||||
handle @mcp {
|
||||
reverse_proxy starpunk-mcp:8001
|
||||
}
|
||||
handle {
|
||||
reverse_proxy starpunk:8000
|
||||
}
|
||||
}
|
||||
|
||||
repair.nerder.land {
|
||||
import hsts
|
||||
|
||||
@@ -11,7 +11,7 @@ services:
|
||||
- '{{ subdomains.gotify }}:{{ docker.hairpin_ip }}'
|
||||
volumes:
|
||||
- starpunk-data:/data
|
||||
environment:
|
||||
environment: &starpunk-env
|
||||
# Site configuration
|
||||
SITE_URL: https://{{ subdomains.starpunk }}
|
||||
SITE_NAME: StarPunk
|
||||
@@ -55,6 +55,34 @@ services:
|
||||
FLASK_DEBUG: 0
|
||||
LOG_LEVEL: INFO
|
||||
DEV_MODE: false
|
||||
|
||||
# MCP server for AI clients (StarPunk v2.15.0, ADR-075): same image, data
|
||||
# and settings; Caddy sends /mcp and its OAuth metadata here. Tokens come
|
||||
# from StarPunk's own IndieAuth server (approve at /auth/authorize).
|
||||
starpunk-mcp:
|
||||
image: {{ subdomains.git }}/phil/starpunk:{{ starpunk_version }}
|
||||
container_name: starpunk-mcp
|
||||
restart: unless-stopped
|
||||
command: ["uvicorn", "starpunk.mcp_server.app:app", "--host", "0.0.0.0", "--port", "8001"]
|
||||
# The image's healthcheck probes the Flask app on :8000
|
||||
healthcheck:
|
||||
test: ["CMD", "python3", "-c", "import socket; socket.create_connection(('localhost', 8001), 2)"]
|
||||
interval: 30s
|
||||
timeout: 5s
|
||||
retries: 3
|
||||
depends_on:
|
||||
- starpunk
|
||||
extra_hosts:
|
||||
- '{{ subdomains.pocketid }}:{{ docker.hairpin_ip }}'
|
||||
- '{{ primary_domain }}:{{ docker.hairpin_ip }}'
|
||||
- '{{ subdomains.social }}:{{ docker.hairpin_ip }}'
|
||||
- '{{ subdomains.gotify }}:{{ docker.hairpin_ip }}'
|
||||
volumes:
|
||||
- starpunk-data:/data
|
||||
environment:
|
||||
<<: *starpunk-env
|
||||
# Only the main container runs the webmention, WebSub and syndication workers
|
||||
BACKGROUND_WORKERS_ENABLED: "false"
|
||||
volumes:
|
||||
# Existing volume (starpunk_starpunk-data) holds the posts and database
|
||||
starpunk-data:
|
||||
|
||||
Reference in new issue
Block a user