Skip to main content

Environment Variables Reference

VariableRequired?DefaultConsumed inPurpose
OPEN_DEVTOOLSOptionalunset (devtools closed)src/core/src/lib.rs (setup hook)Set to "true" to auto-open the webview devtools window on launch
DATABASE_URLOptional (only for sqlx CLI usage)noneNot read by the app itself; only used by the sqlx CLI for migrations/CLI toolingPoints sqlx migrate/sqlx database commands at the real imh.db file — see Troubleshooting

Notes

  • Frontend variables must be prefixed with VITE_ to be exposed to the Vite/React bundle; anything without that prefix is invisible to import.meta.env.
  • The Writing module's AI grading feature needs no environment variables — credentials are configured at runtime from Admin → AI Configurations and stored encrypted in the local SQLite database. See Installation & Local Setup.
  • OPEN_DEVTOOLS and DATABASE_URL are shell environment variables (not VITE_-prefixed), since they're consumed by the Rust process / CLI tooling, not the frontend bundle.
  • No secrets should ever be committed — use .env.local (gitignored), never .env or source-controlled config, for real API keys.