AutoVio is configured via environment variables. Copy .env.example to .env and set the values below.
Variable Description 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.
Variable Description Default PORTBackend HTTP port. 3001VIRAGEN_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:
Variable Description MONGODB_USERNAMEDatabase username. MONGODB_PASSWORDDatabase password. MONGODB_DB_NAMEDatabase name. MONGODB_AUTH_SOURCEAuth source (e.g. admin).
Variable Description Default JWT_EXPIRES_INAccess token expiry (e.g. 7d). 7dJWT_REFRESH_EXPIRES_INRefresh token expiry (e.g. 30d). 30d
For migrations or initial setup, you can create a default admin user:
Variable Description 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
JWT_SECRET=your-super-secret-jwt-key-change-in-production
JWT_REFRESH_EXPIRES_IN=30d