Configuration

NeNe Corpus is configured via a .env file in the project root. On Tier A, the web installer writes this file for you.

Required variables

VariableDescription
APP_URLFull URL of your installation, e.g. https://corpus.example.com
DB_HOSTMySQL host
DB_PORTMySQL port (default 3306)
DB_NAMEDatabase name
DB_USERDatabase user
DB_PASSDatabase password
LOCAL_JWT_SECRETRandom secret for JWT signing (min 32 chars)
ANTHROPIC_API_KEYYour Anthropic API key (sk-ant-...)

Optional: SMTP

Required for email notifications and password reset emails.

VariableDescription
SMTP_HOSTSMTP server hostname
SMTP_PORTSMTP port (587 for STARTTLS, 465 for SSL)
SMTP_USERSMTP username
SMTP_PASSSMTP password
SMTP_FROMSender email address
SMTP_FROM_NAMESender display name
SMTP_SECUREtls (STARTTLS) or ssl
Without SMTP configured, email notifications and password reset emails are silently skipped. The Admin UI shows an alert when SMTP is not set up.

Admin UI settings

Many settings are managed through the Admin UI (Settings modal) and stored in the database:

  • LLM settings — model, temperature, system prompt, fallback message
  • Chat limits — message length, rate limits, daily token budgets
  • Appearance — widget theme, colors, hero text, avatar, custom CSS
  • Notifications — daily report recipients, rate-limit alert thresholds

Security notes

  • Never commit .env to version control.
  • LOCAL_JWT_SECRET should be cryptographically random: openssl rand -hex 32
  • ANTHROPIC_API_KEY is stored in .env only and never exposed to the browser.
  • On Tier A, place .env one level above public_html/ if possible.