Skip to content

Configuration

AutoVio is configured via environment variables. Copy .env.example to .env and set the values below.

VariableDescription
MONGODB_URIMongoDB connection string (e.g. mongodb://localhost:27017 or Atlas URI).
JWT_SECRETSecret key for signing JWT access and refresh tokens. Use a long, random value in production.
VariableDescriptionDefault
PORTBackend HTTP port.3001
VIRAGEN_DATA_DIRRoot directory for binary files (project/work media, assets).packages/backend/data

If you don’t embed credentials in MONGODB_URI, you can set:

VariableDescription
MONGODB_USERNAMEDatabase username.
MONGODB_PASSWORDDatabase password.
MONGODB_DB_NAMEDatabase name.
MONGODB_AUTH_SOURCEAuth source (e.g. admin).
VariableDescriptionDefault
JWT_EXPIRES_INAccess token expiry (e.g. 7d).7d
JWT_REFRESH_EXPIRES_INRefresh token expiry (e.g. 30d).30d

For migrations or initial setup, you can create a default admin user:

VariableDescription
DEFAULT_ADMIN_EMAILAdmin email (e.g. admin@autovio.local).
DEFAULT_ADMIN_PASSWORDAdmin password (change in production).
DEFAULT_ADMIN_NAMEAdmin display name.

AI provider API keys are not set in the backend .env. They are configured per user in the Settings UI (or via API/MCP). The backend reads provider and API key from request headers (e.g. x-llm-provider, x-api-key) or from the MCP server configuration.

MONGODB_URI=mongodb://localhost:27017
MONGODB_DB_NAME=autovio
PORT=3001
JWT_SECRET=your-super-secret-jwt-key-change-in-production
JWT_EXPIRES_IN=7d
JWT_REFRESH_EXPIRES_IN=30d