Files
Shadowbroker/docker-compose.relay.yml
Claude 7f7fe7aef5 Run the relay mesh-only and patch Next.js and PostCSS
- docker-compose.relay.yml: default MESH_ONLY=true with the Infonet sync
  workers kept on (SHADOWBROKER_MESH_NODE_RUNTIME=true), like meshnode.sh.
  Measured: the full backend takes 37 s to answer and settles around 1.5 GB
  RSS at 30-50% CPU; mesh-only answers in 3 s at about 145 MB. The relay's
  2 GB limit left the full mode little headroom. Both stay overridable
  from .env.
- Next.js 16.2.7 -> 16.3.8: fixes the App Router proxy bypass advisory;
  proxy.ts is the CSRF boundary for privileged API routes.
- PostCSS override 8.5.15 -> 8.5.28: fixes the source-map path traversal
  advisories. npm audit (production) now reports only maplibre-gl, whose
  fix needs a major upgrade; the app does not pass HTML to MapLibre.
- Next 16.3 type-checks every file tsconfig includes, so test-only typing
  errors failed the build; build against tsconfig.build.json (tests
  excluded) as before. Tests remain type-checked by Vitest.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UeX9wuqeVAQNr22zQHWj2H
2026-10-22 04:57:47 +00:00

33 lines
1013 B
YAML

# Minimal relay-node compose — backend only, no frontend needed.
services:
backend:
image: ghcr.io/bigbodycobain/shadowbroker-backend:latest
container_name: shadowbroker-relay
ports:
- "127.0.0.1:8000:8000"
env_file: .env
environment:
# Keep Tor wormhole up across redeploys (no NODE UI on headless relay).
MESH_INFONET_RELAY_AUTO_WORMHOLE: "true"
MESH_ARTI_ENABLED: "true"
# A relay serves the mesh only: skip the map-data fetchers (about 1.5 GB
# and 30-50% CPU) but keep the Infonet sync workers running.
MESH_ONLY: "${MESH_ONLY:-true}"
SHADOWBROKER_MESH_NODE_RUNTIME: "${SHADOWBROKER_MESH_NODE_RUNTIME:-true}"
volumes:
- relay_data:/app/data
restart: unless-stopped
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8000/api/health"]
interval: 30s
timeout: 10s
retries: 3
start_period: 60s
deploy:
resources:
limits:
memory: 2G
volumes:
relay_data: