feat: centralize application configuration using environment variables and add dynamic CORS support
This commit is contained in:
14
notes-api/.env.example
Normal file
14
notes-api/.env.example
Normal file
@@ -0,0 +1,14 @@
|
||||
# Server Configuration
|
||||
HOST=127.0.0.1
|
||||
PORT=3000
|
||||
|
||||
# Database
|
||||
DATABASE_URL=sqlite:data.db?mode=rwc
|
||||
|
||||
# Security
|
||||
# Generate a secure random string for production (min 64 chars recommended)
|
||||
SESSION_SECRET=k-notes-super-secret-key-must-be-at-least-64-bytes-long!!!!
|
||||
|
||||
# CORS
|
||||
# Comma-separated list of allowed origins
|
||||
CORS_ALLOWED_ORIGINS=http://localhost:5173
|
||||
Reference in New Issue
Block a user