Deploy
PostgreSQL / SQLite
RushDB uses a relational database (separate from Neo4j) to store project metadata, user accounts, and API keys.
Choosing a Backend
| SQLite | PostgreSQL | |
|---|---|---|
| Setup | Zero config | Requires a running Postgres instance |
| Best for | Single-node, low traffic, dev/staging | Production, HA, multi-instance |
| Persistence | File on disk | External service |
| Scale | Single process | Horizontal scaling |
Use SQLite to get started quickly. Migrate to PostgreSQL before going to production if you need concurrent writes or plan to run multiple RushDB instances.
SQLite Setup
Set in .env:
SQL_DB_TYPE=sqlite
SQL_DB_PATH=./data/rushdb.db
Ensure the data/ directory is persisted via a Docker volume:
# docker-compose.yml (excerpt)
volumes:
- ./data:/app/data
PostgreSQL Setup
- Docker Compose
- External PostgreSQL
The full Compose stack ships with a PostgreSQL 16 service. Set credentials in .env:
SQL_DB_TYPE=postgres
SQL_DB_URL=postgresql://rushdb:your-strong-password@postgres:5432/rushdb
Point RushDB at an existing PostgreSQL 14+ instance:
SQL_DB_TYPE=postgres
SQL_DB_URL=postgresql://rushdb:your-strong-password@your-pg-host.example.com:5432/rushdb
Create the database and user before starting RushDB:
CREATE USER rushdb WITH PASSWORD 'your-strong-password';
CREATE DATABASE rushdb OWNER rushdb;
Backups
Always back up the relational database alongside Neo4j. For SQLite, copy the .db file. For PostgreSQL, use pg_dump:
pg_dump -h localhost -U rushdb rushdb > rushdb_backup_$(date +%Y%m%d).sql