Environment Variables

Configuration reference for self-hosted server operation and connected Cloud mode with PostgreSQL and WorkOS.

Deployment modes

ModeWhat it enablesWho configures services
Browser-local/defaultStateless API and browser persistenceNo external services required
Self-hosted connected modeAccount-backed storage, sync, sharing, and historyThe operator
Rustume CloudThe same connected capabilities on a ready-to-use hosted deploymentRustume

Hosted users do not configure environment variables. This page is for operators running the open-source application or maintaining the hosted service.

Common settings

VariableDefaultPurpose
PORT3000HTTP listen port
RUST_LOGinfoRust tracing filter
CORS_ORIGIN*Allowed browser origins; set an explicit origin for credentialed requests
RUSTUME_STATIC_DIR/app/webBuilt web UI directory
RUSTUME_TEMPLATES_DIRunsetDirectory of .typ template overrides (native CLI/server only; see Templates)
SENTRY_DSNunsetOptional Sentry error tracking
METRICS_TOKENunsetRequired bearer token for /metrics to return telemetry

Connected mode settings

Cloud state is initialized when RUSTUME_CLOUD is true and DATABASE_URL is non-empty. Once enabled, these identity and persistence settings are required:

VariablePurpose
RUSTUME_CLOUDSet to true or 1 to enable connected mode
DATABASE_URLPostgreSQL connection string
WORKOS_CLIENT_IDWorkOS AuthKit application client ID
WORKOS_API_KEYServer-side WorkOS API key
WORKOS_REDIRECT_URIRegistered OAuth callback URL
SESSION_SECRETSession signing secret, at least 32 characters
RESEND_API_KEYResend API key; required together with EMAIL_FROM to enable transactional email
EMAIL_FROMSender address for outbound mail (for example [email protected])

Connected mode always requires authentication. Render, template, resume, and account routes return 401 without a valid session, and there is no setting that re-opens them anonymously. Run without RUSTUME_CLOUD for an open, self-hosted deployment.

RUSTUME_REQUIRE_AUTH was removed and is no longer read. Connected deployments that previously left it unset served those routes anonymously and will now return 401.

Set TRUSTED_PROXY=true only when the server is behind a trusted proxy and may rely on X-Forwarded-For when calling WorkOS. The same flag enables X-Real-IP and append-mode X-Forwarded-For for rate-limit key extraction — see Rate Limits.

Rate limits (cloud mode)

When connected mode is enabled, per-route rate limits apply. See Rate Limits for defaults, route groups, and client behavior.

VariableDefaultPurpose
RATE_LIMIT_RESUME_CRUD_PER_MIN300Resume list/get/create/update/delete and bulk JSON export
RATE_LIMIT_RESUME_CRUD_BURST30Short burst allowance for resume CRUD
RATE_LIMIT_IMPORT_PER_MIN10Bulk import
RATE_LIMIT_PREVIEW_PER_MIN60Preview render
RATE_LIMIT_PDF_PER_MIN20PDF render and bulk PDF export
RATE_LIMIT_AUTH_PER_MIN10Auth login/callback/logout/me
RATE_LIMIT_HEALTH_PER_MIN60Unauthenticated health checks (per IP)
RATE_LIMIT_METRICS_PER_MIN60Metrics scrapes (per IP)
RATE_LIMIT_UNAUTHENTICATED_PER_MIN30Other unauthenticated traffic (per IP)
RATE_LIMIT_BILLABLE_PER_MIN30Templates, parse, validate (available in all connected deployments; env name is historical)

Local connected example

docker compose --profile cloud up postgres
export RUSTUME_CLOUD=true
export DATABASE_URL=postgres://user:password@localhost:5432/rustume
export WORKOS_CLIENT_ID=client_...
export WORKOS_API_KEY=sk_...
export WORKOS_REDIRECT_URI=http://localhost:3000/auth/callback
export SESSION_SECRET="$(openssl rand -hex 32)"
export RESEND_API_KEY=re_...
export EMAIL_FROM=[email protected]
export METRICS_TOKEN="$(openssl rand -hex 32)"
export CORS_ORIGIN=http://localhost:5173
cargo run -p rustume-server

Hosted-stack configuration for billing, managed object storage, and infrastructure provisioning is an operator concern, not a prerequisite for users running the open-source connected features.