Skip to content

Deployment Overview ​

Sibyl can be deployed in multiple configurations, from local development to production Kubernetes clusters.

Architecture ​

Sibyl consists of four components plus one unified storage backend:

ComponentPurposePort
BackendFastAPI + MCP server (sibyld serve)3334
Workerarq job queue processor-
FrontendNext.js 16 web UI3337
SurrealDBGraph + content + auth8000*

*Default internal ports. External mappings vary by deployment mode.

Runtime Boundary ​

  • SurrealDB is the only data service Sibyl needs, for local, single-host, and production deployments alike.
  • Redis/Valkey coordination is explicit opt-in. Use it for multi-process or multi-replica deployments by setting SIBYL_COORDINATION_BACKEND=redis or Helm coordinationBackend: redis.
  • Recovery uses SurrealDB backups and Sibyl archive restores. See Backup And Restore.
                                   +------------------+
                                   |    Frontend      |
                                   |   (Next.js 16)   |
                                   |     :3337        |
                                   +--------+---------+
                                            |
+------------------+               +--------+---------+
|    MCP Client    |               |      Kong /      |
| (Claude, etc.)   +-------------->+     Ingress      |
+------------------+     /mcp      +--------+---------+
                                            |
                         /api/*    +--------+---------+
                         +-------->+     Backend      |
                                   | (FastAPI + MCP)  |
                                   |     :3334        |
                                   +--------+---------+
                                            |
                                            | ws://:8000/rpc
                                            v
                                   +------------------+
                                   |     SurrealDB    |
                                   |  graph + content |
                                   |      + auth      |
                                   |      :8000       |
                                   +--------+---------+
                                            ^
                                            |
                                   +--------+---------+
                                   |     Worker       |
                                   |  (arq processor) |
                                   +------------------+

See Storage Modes for how each process connects to SurrealDB.

Deployment Modes ​

1. Local Development (Docker Compose) ​

Best for: Quick local development and testing.

2. Production Kubernetes ​

Best for: Production deployments with HA and scaling.

3. Single Host (Ansible) ​

Best for: A personal instance on one small cloud VM.

  • One host, no Kubernetes
  • Docker Compose stack provisioned by the bundled Ansible role
  • Caddy TLS via the Cloudflare DNS-01 challenge
  • Pairs with Tailscale for a private, zero-public-port deployment
  • Single-Host Guide

Quick Comparison ​

FeatureDocker ComposeProduction K8sSingle Host
Setup time1 minuteVaries~10 minutes
Hot reloadYesNoNo
Kong GatewayNoYesNo
TLSNoYesYes (Caddy)
AutoscalingNoYes (HPA)No
Multi-replicaNoYesNo
Resource requirementsLowHighLow
Production-likeNoYesMostly

Port Mappings by Environment ​

Docker Compose (Local Dev) ​

ServiceHost PortContainer PortNotes
Backend33343334API + MCP
Frontend33373337Next.js UI
SurrealDB (default)80008000ws/http, RPC at /rpc
Redis/Valkey63816379Optional coordination

Next Steps ​

Released under the Apache-2.0 License.