local-web-search/.env.example
User e6c2cc1e8c Prepare for public release: AGPL license, curl installer, bearer-token auth
- LICENSE: AGPL-3.0
- install.sh: curl-pipeable bootstrap for Linux/macOS (VPS/LXC) — installs
  Docker if missing, clones, generates strong LWSS_API_KEY + SearXNG secret,
  compose up, prints the ready-to-run 'claude mcp add' command; idempotent and
  preserves .env on re-run
- auth: optional bearer token (LWSS_API_KEY) on all orchestrator MCP + REST
  requests via middleware; /health exempt; empty key disables auth (LAN only);
  constant-time compare
- compose: configurable bind address (ORCHESTRATOR_BIND, default 0.0.0.0) so
  the endpoint can stay localhost-only behind a tunnel; API key plumbed through
- docker-compose.override.yml pattern (gitignored) + .example for machine-local
  config like LAN SearXNG extra_hosts
- README: install one-liner, auth + security (SSRF/tunnel) notes, license
- PRD: auth documented in §8; multi-tenant non-goal clarified

Verified: auth rejects unauthenticated REST + MCP (401), passes with a valid
bearer token, /health stays open; full dockerized stack healthy; MCP client
connects only with the Authorization header.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-06 00:43:04 -07:00

33 lines
882 B
Text

# Copy to .env and adjust. All values shown are the defaults used in compose.
# Public port + bind address for the orchestrator (MCP + REST; only exposed
# service). Bind 127.0.0.1 to keep it localhost-only (reach it over a tunnel).
ORCHESTRATOR_PORT=8000
ORCHESTRATOR_BIND=0.0.0.0
# Bearer token required on every request (Authorization: Bearer <key>).
# Leave empty to DISABLE auth — only safe on trusted/LAN networks.
# install.sh generates a strong value automatically.
LWSS_API_KEY=
# Cache TTLs (seconds)
RENDER_CACHE_TTL=3600
SEARCH_CACHE_TTL=300
EXTRACT_CACHE_TTL=3600
# Renderer
RENDER_CONCURRENCY=4
RENDER_TIMEOUT_MS=30000
RENDER_WAIT_POLICY=networkidle
RENDER_RETRIES=1
# Politeness: max renders per domain per window
DOMAIN_RATE_LIMIT=10
DOMAIN_RATE_WINDOW_S=10
# Timeouts
STAGE_TIMEOUT_S=60
SEARCH_TIMEOUT_S=15
# SearXNG
SEARXNG_SECRET=change-me-lwss-internal