Skip to main content

RushDB Platform

RushDB is a single NestJS application built on the Fastify adapter. It serves both the REST API and (optionally) the built-in dashboard as static files from the same process.

Runtime overview

AttributeValue
FrameworkNestJS + Fastify
Node.js18 – 22
Default port3000 (all interfaces — 0.0.0.0)
API prefix/api/v1
Swagger UI/api
Body limit2 GB (for large batch imports)
Health endpointGET /"RushDB is running"
Settings endpointGET /settings → OAuth flags, feature flags

Key environment variables

VariableRequiredDefaultDescription
RUSHDB_SELF_HOSTEDMust be true. Enables self-hosted mode, disables billing, seeds the admin account.
RUSHDB_PORT3000Port the API listens on.
RUSHDB_LOGINadminAdmin account login created on first startup.
RUSHDB_PASSWORDpasswordAdmin password — used only if the account does not yet exist.
RUSHDB_AES_256_ENCRYPTION_KEYExactly 32 characters. AES-256 key for token encryption and JWT signing. Generate: openssl rand -hex 32
RUSHDB_SERVE_STATICfalseSet to true to serve the dashboard from the same process (see below).
RUSHDB_DASHBOARD_URLPublic URL of the dashboard. Used in OAuth redirects and email links.
RUSHDB_PUBLIC_URLPublic URL of the API. Used as the OAuth issuer (RUSHDB_OAUTH_ISSUER).

See Environment Variables for the full reference.


Startup dependencies

RushDB will crash on startup if it cannot reach Neo4j or the SQL database. The startup order must be:

1. Neo4j (bolt :7687 must accept connections)
2. PostgreSQL / SQLite file accessible
3. RushDB platform process

In the Docker Compose setup this is enforced with depends_on + condition: service_healthy on both Neo4j and PostgreSQL. When running from source, start the databases first.

Built-in wait-for-Neo4j

The DatabaseModule retries the Neo4j HTTP health endpoint (http://neo4j:7474) up to 15 times with a 5-second interval before raising an error. This provides ~75 seconds of tolerance for slow Neo4j startup.


Dashboard serving

RushDB can serve the built-in dashboard from the same process or delegate it to a CDN / separate origin.

Set RUSHDB_SERVE_STATIC=true. The public/ directory (pre-built dashboard assets) is served at /*, excluding /api*.

RUSHDB_SERVE_STATIC=true
RUSHDB_DASHBOARD_URL=https://rushdb.example.com

Requests to / return the dashboard HTML. Requests to /api/v1/* are handled by the API router.

note

When RUSHDB_SERVE_STATIC=true, the GET / health endpoint is replaced by the dashboard index page. Use GET /settings for liveness probes in this mode.


CORS

CORS is enabled by default and accepts requests from any origin (origin: true). Custom headers allowed in requests:

Authorization
X-Workspace-Id
X-Project-Id
X-Transaction-Id
Content-Disposition
Content-Type

If you need to restrict origins, place a reverse proxy (nginx, Caddy) in front and enforce Origin checking there — the application-level CORS is intentionally permissive for self-hosted flexibility.


Swagger / OpenAPI

The OpenAPI spec is auto-generated and served at:

http(s)://your-host:3000/api

All API endpoints require a Bearer token. The Swagger UI has a built-in "Authorize" button to paste a project token.


CLI commands

RushDB ships with a console CLI (requires RUSHDB_SELF_HOSTED=true). Run from the container or from platform/core/dist/:

# Change a user's password
docker exec -it rushdb node dist/main update-password <login> <newPassword>

# Create a new user
docker exec -it rushdb node dist/main create-user <login> <password>

# Restore a project from a backup dump
docker exec -it rushdb node dist/main db-restore <projectId> <filePath>

For docker compose, replace docker exec -it rushdb with docker compose exec rushdb.


Resource requirements

These are baseline figures for a lightly loaded self-hosted instance:

ResourceMinimumRecommended
CPU0.25 vCPU1 vCPU
Memory256 MB512 MB – 1 GB
DiskDepends on SQLite PVC size

Neo4j typically dominates resource consumption. See Neo4j & Aura for its requirements.