1+ # ================================
2+ # Cognize API Server Configuration
3+ # ================================
4+ # Copy this file to .env and update with your actual values
5+ # DO NOT commit .env files to version control
6+
7+ # ======================
8+ # Server Configuration
9+ # ======================
10+ # Port number for the server to listen on
11+ PORT = 4000
12+
13+ # Environment mode: dev, staging, prod
14+ ENVIRONMENT = dev
15+
16+ # ======================
17+ # Database Configuration
18+ # ======================
19+ # PostgreSQL connection string
20+ # Format: postgres://[username[:password]@][host[:port]]/database[?options]
21+
22+ # Local development (with Docker)
23+ DB_STRING = postgres://root:root@localhost:5432/cognize?sslmode=disable
24+
25+ # Production example (uncomment and modify for production)
26+ # DB_STRING=postgres://username:password@db-host:5432/cognize?sslmode=require
27+
28+ # ======================
29+ # Authentication & Security
30+ # ======================
31+ # JWT signing secret - MUST be at least 32 characters long
32+ # Generate with: openssl rand -hex 32
33+ JWT_SECRET = change-this-to-a-long-secure-random-string-32-chars-min
34+
35+ # Google OAuth Configuration
36+ # Get these from Google Cloud Console > APIs & Services > Credentials
37+ GOOGLE_OAUTH_CLIENT_ID = your-google-oauth-client-id.apps.googleusercontent.com
38+ GOOGLE_OAUTH_CLIENT_SECRET = your-google-oauth-client-secret
39+ GOOGLE_OAUTH_REDIRECT_URL = http://localhost:3000/auth/callback
40+
41+ # ======================
42+ # Email Configuration (Optional)
43+ # ======================
44+ # SMTP settings for sending emails
45+ # Gmail example:
46+ SMTP_HOST = smtp.gmail.com
47+ SMTP_PORT = 587
48+ SMTP_USERNAME = your-email@gmail.com
49+ SMTP_PASSWORD = your-app-password
50+
51+ # AWS SES example:
52+ # SMTP_HOST=email-smtp.us-east-1.amazonaws.com
53+ # SMTP_PORT=587
54+ # SMTP_USERNAME=your-ses-smtp-username
55+ # SMTP_PASSWORD=your-ses-smtp-password
56+
57+ # ======================
58+ # Logging Configuration (Optional)
59+ # ======================
60+ # Axiom logging service integration
61+ # Get these from axiom.co after creating an account
62+ AXIOM_TOKEN = your-axiom-api-token
63+ AXIOM_ORG = your-axiom-organization
64+ AXIOM_DATASET = cognize-logs
65+
66+ # ======================
67+ # Additional Security (Optional)
68+ # ======================
69+ # Additional encryption secret for sensitive operations
70+ # Generate with: openssl rand -hex 32
71+ ENC_SECRET = another-long-secure-random-string-for-encryption
72+
73+ # ======================
74+ # Development Notes
75+ # ======================
76+ # 1. For production, use strong, randomly generated secrets
77+ # 2. Enable SSL/TLS for database connections in production
78+ # 3. Use managed database services (AWS RDS, Google Cloud SQL, etc.)
79+ # 4. Never commit this file to version control
80+ # 5. Rotate secrets regularly in production environments
81+ # 6. Use environment-specific configuration files
0 commit comments