Skip to main content

Local brain (no auth, SQLite)

Prerequisites: Python 3.11+, a POSIX shell; OpenSSH and rsync only if you’ll use sandboxes; provider credentials only if you’ll provision real ones.
1

Install and start

Auto-reload while editing backend code: python3 scripts/dev_http_reload.py --host 127.0.0.1 --port 8787.
2

Check it

3

Point a client at it

Local mode is auth-free. For a headless client or the runner:
For an interactive client, register the MCP server URL http://127.0.0.1:8787/mcp the way that client registers any HTTP MCP server; there is no OAuth to complete.

Reference Compose stack

From merv/. The base file runs control (the brain), minio, and mgmtkey (a development-only management SSH key). Add one database overlay.
Binds Postgres to 127.0.0.1:5432 and supplies MERV_DB_URL to control. Override MERV_POSTGRES_PASSWORD and MERV_POSTGRES_PORT as needed.

Preflight the database

Checks connectivity, read/write, public privileges, transactional DDL, TLS, and that session advisory locks survive a round trip. Rejects the transaction-pooler port. Never prints the password.

Required hosted configuration

merv-control forces MERV_MODE=control. Startup requires: MERV_ADMIN_TOKEN doesn’t gate startup, but without it every /api/admin/* call is denied. Optional heavy object storage: MERV_STORAGE_PROVIDER plus bucket/credentials; MERV_STORAGE_MAX_UPLOAD_BYTES (default 50 GiB) caps per-object size, overridable per project below that ceiling. MERV_REQUIRE_SANDBOX_BACKEND=1 refuses to start if the selected provider is unhealthy. .env.example lists every variable; legacy RESEARCH_PLUGIN_* names still work as fallbacks (MERV_* wins). The brain serves plain HTTP on 8787 — terminate TLS at a proxy or load balancer. Next: Configure auth.