diff --git a/.env.production b/.env.production index 9fcf7ac..941ad9b 100644 --- a/.env.production +++ b/.env.production @@ -1,86 +1,94 @@ # ============================================ -# Document Translation API - Production Environment +# Wordly.art - .env de production +# ============================================ +# Copier ce fichier en .env sur le serveur +# cp .env.production .env +# Puis remplacer les valeurs [A CHANGER] # ============================================ -# IMPORTANT: Review and update all values before deployment -# =========================================== -# Application Settings -# =========================================== -APP_NAME=Document Translation API +# ---- Application ---- +APP_NAME=Wordly APP_ENV=production DEBUG=false LOG_LEVEL=INFO -# =========================================== -# Server Configuration -# =========================================== -HTTP_PORT=80 -HTTPS_PORT=443 +# ---- Domaine ---- +DOMAIN=wordly.art +NEXT_PUBLIC_API_URL=https://wordly.art BACKEND_PORT=8000 FRONTEND_PORT=3000 -# =========================================== -# Domain Configuration -# =========================================== -DOMAIN=translate.yourdomain.com -NEXT_PUBLIC_API_URL=https://translate.yourdomain.com +# ---- Service de traduction par defaut ---- +# Choisir: google, ollama, deepseek, minimax, deepl, openai, openrouter +TRANSLATION_SERVICE=google -# =========================================== -# Translation Service Configuration -# =========================================== -TRANSLATION_SERVICE=ollama +# ---- Google (gratuit, toujours actif) ---- +GOOGLE_TRANSLATE_ENABLED=true + +# ---- Ollama (local, gratuit) ---- +OLLAMA_ENABLED=false OLLAMA_BASE_URL=http://ollama:11434 OLLAMA_MODEL=llama3 -# DeepL API (optional) +# ---- DeepSeek ---- +DEEPSEEK_ENABLED=false +DEEPSEEK_API_KEY= +DEEPSEEK_MODEL=deepseek-chat +DEEPSEEK_BASE_URL=https://api.deepseek.com/v1 + +# ---- Minimax ---- +MINIMAX_ENABLED=false +MINIMAX_API_KEY= +MINIMAX_MODEL=MiniMax-M1 +MINIMAX_BASE_URL=https://api.minimax.chat/v1 + +# ---- DeepL ---- +DEEPL_ENABLED=false DEEPL_API_KEY= -# OpenAI API (optional) +# ---- OpenAI ---- +OPENAI_ENABLED=false OPENAI_API_KEY= OPENAI_MODEL=gpt-4o-mini +OPENAI_BASE_URL=https://api.openai.com/v1 -# =========================================== -# File Upload Settings -# =========================================== +# ---- OpenRouter ---- +OPENROUTER_ENABLED=false +OPENROUTER_API_KEY= +OPENROUTER_MODEL=deepseek/deepseek-chat + +# ---- Upload ---- MAX_FILE_SIZE_MB=50 ALLOWED_EXTENSIONS=.docx,.xlsx,.pptx -# =========================================== -# Rate Limiting -# =========================================== +# ---- Rate Limiting ---- RATE_LIMIT_ENABLED=true RATE_LIMIT_REQUESTS_PER_MINUTE=60 RATE_LIMIT_TRANSLATIONS_PER_MINUTE=10 RATE_LIMIT_TRANSLATIONS_PER_HOUR=100 RATE_LIMIT_TRANSLATIONS_PER_DAY=500 -# =========================================== -# Security (CHANGE THESE!) -# =========================================== +# ---- Admin ---- ADMIN_USERNAME=admin +ADMIN_PASSWORD_HASH=CHANGE_WITH_BCRYPT_HASH -# Use bcrypt hash — NEVER store plaintext password in production -# Generate with: python -c "from passlib.context import CryptContext; print(CryptContext(schemes=['bcrypt']).hash('YOUR_PASSWORD'))" -ADMIN_PASSWORD_HASH= +# ---- Secrets (deja generes) ---- +JWT_SECRET_KEY=84-MniOv3rOZZ3FczwDvsNNHqZRf8yKI06uMNQGAgMSV8yAJ19comNe6FHHcnVyeNm-fvDxlcb9CWe40y4oy7A +ADMIN_TOKEN_SECRET=1301880be1bc8026676d7f4fb13ae1c70fcd2abbd2f2cdfcb044eea5c7005ce3 +CORS_ORIGINS=https://wordly.art -# JWT secret key — REQUIRED, generates random key at startup if not set (breaks auth on restart) -# Generate with: python -c "import secrets; print(secrets.token_urlsafe(64))" -JWT_SECRET_KEY= +# ---- Database ---- +POSTGRES_USER=translate +POSTGRES_PASSWORD=yLLgkEvt6mvzGDdoqtQvI1vEgMmR-W75ZTPW5StaIAU +POSTGRES_DB=translate_db -# Admin token secret — REQUIRED, generates random key at startup if not set (breaks admin sessions on restart) -# Generate with: python -c "import secrets; print(secrets.token_hex(32))" -ADMIN_TOKEN_SECRET= - -# CORS Configuration -CORS_ORIGINS=https://translate.yourdomain.com - -# =========================================== -# Monitoring (Optional) -# =========================================== +# ---- Monitoring ---- GRAFANA_USER=admin -GRAFANA_PASSWORD=CHANGE_THIS_TOO +GRAFANA_PASSWORD=WordlyGrafana2026! -# =========================================== -# SSL Configuration -# =========================================== -LETSENCRYPT_EMAIL=admin@yourdomain.com +# ---- Stripe ---- +STRIPE_SECRET_KEY= +STRIPE_WEBHOOK_SECRET= +STRIPE_STARTER_PRICE_ID= +STRIPE_PRO_PRICE_ID= +STRIPE_BUSINESS_PRICE_ID=