138 lines
4.6 KiB
Text
138 lines
4.6 KiB
Text
# ==========================================
|
|
# Enterprise AI Hub "Nexus" - Environment Variables
|
|
# ==========================================
|
|
# Copy this file to .env and fill in your actual values
|
|
# NEVER commit .env to version control!
|
|
|
|
# ==========================================
|
|
# Application Settings
|
|
# ==========================================
|
|
# Environment: development | staging | production
|
|
ENVIRONMENT=production
|
|
|
|
# Enable debug mode (development only!)
|
|
DEBUG=false
|
|
|
|
# Public URL of the backend (used for CORS, webhooks)
|
|
BACKEND_BASE_URL=https://ai-sandbox.oliver.solutions
|
|
|
|
# Gunicorn workers (rule of thumb: 2 * CPU + 1)
|
|
WORKERS_COUNT=4
|
|
|
|
# Logging: json (production) or text (development)
|
|
LOG_LEVEL=INFO
|
|
LOG_FORMAT=json
|
|
|
|
# Rate limiting: requests per minute per user/IP
|
|
RATE_LIMIT_PER_MINUTE=60
|
|
|
|
# CORS allowed origins (comma-separated)
|
|
CORS_ORIGINS=https://ai-sandbox.oliver.solutions
|
|
|
|
# Trusted hosts (empty = allow all; comma-separated)
|
|
TRUSTED_HOSTS=ai-sandbox.oliver.solutions
|
|
|
|
# ==========================================
|
|
# Database Configuration
|
|
# ==========================================
|
|
POSTGRES_DB=nexus_db
|
|
POSTGRES_USER=nexus_user
|
|
POSTGRES_PASSWORD=your_secure_password_here_min_16_chars
|
|
|
|
# Database URL (used by the backend container — host is "db" in Docker)
|
|
DATABASE_URL=postgresql://nexus_user:your_secure_password_here_min_16_chars@db:5432/nexus_db
|
|
|
|
# ==========================================
|
|
# Redis Configuration
|
|
# ==========================================
|
|
REDIS_URL=redis://redis:6379/0
|
|
|
|
# ==========================================
|
|
# Qdrant Vector Database
|
|
# ==========================================
|
|
QDRANT_URL=http://qdrant:6333
|
|
|
|
# ==========================================
|
|
# Microsoft Entra ID (Azure AD) Authentication
|
|
# ==========================================
|
|
# Get these from Azure Portal > App Registrations
|
|
ENTRA_CLIENT_ID=your_client_id_here
|
|
ENTRA_CLIENT_SECRET=your_client_secret_here
|
|
ENTRA_TENANT_ID=your_tenant_id_here
|
|
ENTRA_REDIRECT_URI=https://ai-sandbox.oliver.solutions/nexus/api/v1/auth/callback
|
|
|
|
# ==========================================
|
|
# LLM Provider API Keys
|
|
# ==========================================
|
|
OPENAI_API_KEY=sk-proj-your_openai_api_key_here
|
|
GOOGLE_API_KEY=AIza_your_google_api_key_here
|
|
ANTHROPIC_API_KEY=sk-ant-your_anthropic_api_key_here
|
|
|
|
# ==========================================
|
|
# JWT Authentication
|
|
# ==========================================
|
|
# Generate: openssl rand -hex 32
|
|
JWT_SECRET=your_jwt_secret_key_min_32_characters_use_openssl_rand_hex_32
|
|
JWT_ALGORITHM=HS256
|
|
JWT_EXPIRATION_MINUTES=15
|
|
REFRESH_TOKEN_EXPIRATION_DAYS=7
|
|
|
|
# ==========================================
|
|
# LlamaParse (Optional — cloud PDF parsing)
|
|
# ==========================================
|
|
LLAMAPARSE_API_KEY=
|
|
|
|
# ==========================================
|
|
# Tavily Web Search (Corrective RAG fallback)
|
|
# ==========================================
|
|
TAVILY_API_KEY=
|
|
|
|
# ==========================================
|
|
# File Upload Configuration
|
|
# ==========================================
|
|
MAX_UPLOAD_SIZE_MB=100
|
|
UPLOAD_DIR=/app/uploads
|
|
|
|
# ==========================================
|
|
# Microsoft Graph API / SharePoint
|
|
# ==========================================
|
|
# Encryption key for stored Graph tokens (falls back to JWT_SECRET)
|
|
GRAPH_ENCRYPTION_KEY=
|
|
GRAPH_CONSENT_REDIRECT_URI=https://ai-sandbox.oliver.solutions/nexus/auth/graph-callback
|
|
SHAREPOINT_WEBHOOK_BASE_URL=https://ai-sandbox.oliver.solutions/nexus
|
|
SHAREPOINT_WEBHOOK_CLIENT_STATE=
|
|
SHAREPOINT_TENANT_DOMAIN=company.sharepoint.com
|
|
|
|
# ==========================================
|
|
# Celery Workers
|
|
# ==========================================
|
|
CELERY_BROKER_URL=redis://redis:6379/0
|
|
CELERY_RESULT_BACKEND=redis://redis:6379/0
|
|
CELERY_CONCURRENCY=2
|
|
|
|
# ==========================================
|
|
# Email Notifications (for Celery task failures)
|
|
# ==========================================
|
|
SMTP_HOST=smtp.gmail.com
|
|
SMTP_PORT=587
|
|
SMTP_USER=your_email@company.com
|
|
SMTP_PASSWORD=your_email_password
|
|
ADMIN_EMAIL=admin@company.com
|
|
|
|
# ==========================================
|
|
# Monitoring (Optional)
|
|
# ==========================================
|
|
SENTRY_DSN=
|
|
|
|
# ==========================================
|
|
# Cloud Run Document Processor (Optional)
|
|
# ==========================================
|
|
# When set, document processing is delegated to Cloud Run HTTP service.
|
|
# When empty, falls back to local DocumentProcessor via Celery.
|
|
CLOUD_RUN_PROCESSOR_URL=
|
|
# Example: CLOUD_RUN_PROCESSOR_URL=https://nexus-processor-XXXXX-ew.a.run.app
|
|
|
|
# Code Interpreter (LibreCodeInterpreter)
|
|
CODE_INTERPRETER_API_KEY=your-secret-key-here
|
|
CODE_INTERPRETER_MINIO_USER=minioadmin
|
|
CODE_INTERPRETER_MINIO_PASSWORD=minioadmin
|