# Production environment configuration for nginx subpath deployment with SSL
# Copy this file to .env.production and configure for your production deployment
# Essential Configuration - Required
AUTH_TOKEN=production-secret-token-change-this
DB_PASSWORD=production-database-password-change-this
# Production Base Path Configuration
# Use full HTTPS URL for production deployments
BASE_URL=https://yourdomain.com/articles
# Alternative examples:
# BASE_URL=https://example.com/md
# BASE_URL=https://docs.company.com/wiki
# BASE_URL=https://internal.company.com/knowledge-base
# Application Settings
PORT=5000
NODE_ENV=production
MCP_SERVER_ENABLED=true
# Database Configuration (Production tuned)
DB_HOST=postgres
DB_PORT=5432
DB_NAME=article_manager
DB_USER=article_user
DB_SSL=false
DB_MAX_CONNECTIONS=50
DB_IDLE_TIMEOUT=30000
DB_CONNECTION_TIMEOUT=5000
# Production Semantic Search Configuration
SEMANTIC_SEARCH_ENABLED=true
EMBEDDING_PROVIDER=openai
EMBEDDING_MODEL=text-embedding-3-small
OPENAI_API_KEY=your-openai-api-key-here
CHUNK_SIZE=500
CHUNK_OVERLAP=50
# Alternative: Use Ollama for local embeddings
# SEMANTIC_SEARCH_ENABLED=true
# EMBEDDING_PROVIDER=ollama
# EMBEDDING_MODEL=nomic-embed-text
# OLLAMA_BASE_URL=http://ollama-server:11434
# Production Logging and Monitoring
LOG_LEVEL=info
ENABLE_REQUEST_LOGGING=true
# Security Notes for Production:
# 1. Use strong, unique AUTH_TOKEN (32+ characters)
# 2. Use strong database password (16+ characters)
# 3. Keep OpenAI API key secure and rotate regularly
# 4. Monitor logs for unauthorized access attempts
# 5. Use HTTPS only (configured in nginx)
# 6. Consider IP-based access restrictions in nginx
# 7. Regular database backups (see docker-compose.production.yml)
# SSL Certificate Requirements:
# - Place cert.pem and key.pem in ./ssl/ directory
# - Ensure certificates are valid for your domain
# - Consider using Let's Encrypt for free SSL certificates
# - Update nginx-production.conf with your domain name
# Deployment Checklist:
# [ ] SSL certificates in ./ssl/ directory
# [ ] Domain DNS configured
# [ ] Firewall allows ports 80/443
# [ ] Strong AUTH_TOKEN and DB_PASSWORD set
# [ ] OpenAI API key configured (if using)
# [ ] Domain name updated in nginx-production.conf
# [ ] Backup strategy configured
# [ ] Monitoring and alerting set up
</content>