Configuration
Environment Variables
Connect a backend to a Rivet control plane with environment variables for endpoints, authentication, runner pools, and the local engine.
These variables wire your process to a Rivet control plane. Variables that configure the RivetKit SDK itself, including logging, storage, and the inspector, are listed in Environment Variables in the Actors docs.
Connection
| Environment Variable | Description |
|---|---|
RIVET_ENDPOINT | Endpoint URL to connect to Rivet control plane. Supports URL auth syntax. |
RIVET_TOKEN | Authentication token for Rivet control plane |
RIVET_NAMESPACE | Namespace to use (default: “default”) |
Public Endpoint
These variables configure how clients connect to your actors.
| Environment Variable | Description |
|---|---|
RIVET_PUBLIC_ENDPOINT | Public endpoint for client connections. Supports URL auth syntax. |
RIVET_PUBLIC_TOKEN | Public token for client authentication |
Runner Configuration
| Environment Variable | Description |
|---|---|
RIVET_POOL | Pool name (default: “default”) |
RIVET_RUNNER_VERSION | Version number for the runner. See Versions & Upgrades. |
RIVET_RUNNER_KIND | Type of runner |
RIVET_TOTAL_SLOTS | Total actor slots available (default: 100000) |
Engine
| Environment Variable | Description |
|---|---|
RIVET_RUN_ENGINE | Set to 1 to spawn the control plane process |
RIVET_RUN_ENGINE_HOST | Host to bind the spawned local engine process to. Defaults to 127.0.0.1. |
RIVET_RUN_ENGINE_PORT | Port to bind the spawned local engine process to. Defaults to 6420. |
RIVET_RUN_ENGINE_VERSION | Version of engine to download |
RIVET_RUN_SERVICES | Set to 1 to run Services with a local Engine, or 0 to disable it. By default, Services follows RivetKit’s local-Engine decision. |
RIVET_SERVICES_BINARY | Path to a local rivet-services binary. |