.env file in the root directory with the following variables.
Required Variables
These variables must be set for VulnTrack to function properly.PostgreSQL database connection string.Format:
postgresql://USER:PASSWORD@HOST:PORT/DATABASEExample: postgresql://postgres:password@localhost:5432/vulntrackThe canonical URL of your VulnTrack deployment. Used by NextAuth.js for redirects and callbacks.Development:
http://localhost:3000Production: https://vulntrack.yourdomain.comSecret key used to encrypt JWT tokens and session cookies.Generate using:
openssl rand -base64 32Public-facing URL used in email templates and client-side redirects.Development:
http://localhost:3000Production: https://vulntrack.yourdomain.comMust match
NEXTAUTH_URL in most cases.Email Configuration
Required for sending invitations, password resets, and notifications.API key from Resend for email delivery.Location: Get from Resend Dashboard > API KeysIf not set, emails will be logged to console instead of sent (mock mode).
Sender email address and display name for outgoing emails.Format:
Display Name <[email protected]>Example: VulnTrack Security <[email protected]>External API Integrations
Optional integrations for CVE data enrichment.API key for NIST National Vulnerability Database.Used to fetch CVE data from the official NVD API. Rate limits are higher with an API key.Register: https://nvd.nist.gov/developers/request-an-api-key
API key for VulnCheck vulnerability intelligence.Provides enhanced CVE data, exploitability indicators, and real-time threat intelligence.Get Started: https://vulncheck.com
Internal Configuration
Node.js environment mode.Values:
development- Enables debug logging and hot reloadproduction- Optimized build with cachingtest- For automated testing
Example Configuration
Create a.env file in the root directory:
.env