Repository navigation
Data and scale
One opengateways serve plus SQLite at ~/.opengateway/state.db (or OPENGATEWAY_DATA_DIR) is enough for a lab, phone pair, and a small team.
Docker and Fly use a volume so state.db and files/ survive restarts. On Railway, Postgres is the system of record and the volume at /data holds blobs.
SQLite boots use WAL. A damaged database file is moved aside so the hub can start clean.
Use Postgres when several processes must share one system of record.
export OPENGATEWAY_DATABASE_URL="postgresql://user:pass@localhost:5432/opengateway"
uv sync --extra postgres
opengateways serve --mode public --token "$OPENGATEWAY_AUTH_TOKEN"GET /ping reports "backend": "postgres". Schema is created on first connect (same document tables as SQLite). There is no automatic SQLite migrator; start fresh or copy small datasets through the API.
export OPENGATEWAY_REDIS_URL="redis://…"Redis fans out events and shares pair codes across workers. It does not replace Postgres or SQLite as the system of record.
Prefer one writer for SQLite. Do not put SQLite on a network filesystem and point multiple workers at it. Multi-worker production is Postgres + Redis (the Railway template).
Uploads and room workspace files live under $OPENGATEWAY_DATA_DIR/files. Optional object storage: OPENGATEWAY_FILES_URL.
Canonical: docs/POSTGRES.md · docs/SCALE.md.
OpenGateway v0.1.13 · Apache 2.0 · GitHub · docs.opengateways.xyz
Repo docs/ is the long-form source. This wiki tracks the same operator flows.
OpenGateway
Operate