Force archive the following proposals: - add-audio-device-selector (complete) - add-embedded-backend-packaging (19/26 tasks) - add-flexible-deployment-options (20/21 tasks) New specs created: - audio-device-management (7 requirements) - embedded-backend (8 requirements) Updated specs: - transcription (+2 requirements for model download progress) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2.0 KiB
2.0 KiB
Tasks: Extract Environment Variables
1. Backend Configuration
- 1.1 Update
backend/app/config.pywith new environment variables- Add: BACKEND_HOST, BACKEND_PORT
- Add: DB_POOL_SIZE, JWT_EXPIRE_HOURS
- Add: UPLOAD_TIMEOUT, DIFY_STT_TIMEOUT, LLM_TIMEOUT, AUTH_TIMEOUT
- Add: TEMPLATE_DIR, RECORD_DIR, MAX_FILE_SIZE, SUPPORTED_AUDIO_FORMATS
- 1.2 Update
backend/app/database.pyto use DB_POOL_SIZE from config - 1.3 Update
backend/app/routers/ai.pyto use Dify timeout configs (DIFY_STT_TIMEOUT, LLM_TIMEOUT) - 1.4 Update
backend/app/routers/auth.pyto use AUTH_TIMEOUT and JWT_EXPIRE_HOURS from config - 1.5 Update
backend/app/routers/export.pyto use TEMPLATE_DIR and RECORD_DIR from config - 1.6 Update
backend/.envwith all new variables - 1.7 Update
backend/.env.examplewith all variables (without sensitive values)
2. Frontend/Electron Configuration
- 2.1 Create
client/.envwith VITE_API_BASE_URL and Whisper settings - 2.2 Create
client/.env.exampleas template - 2.3 Update
client/src/services/api.jsto use import.meta.env.VITE_API_BASE_URL - 2.4 Update
client/src/main.jsto pass Whisper env vars to Sidecar process
3. Startup Scripts
- 3.1 Update
start.shto load environment variables properly - 3.2 Create
scripts/deploy-backend.shfor standalone backend deployment
4. Deployment Documentation
- 4.1 Create
docs/1panel-deployment.mdwith step-by-step guide- Include: Prerequisites and system requirements
- Include: Python environment setup
- Include: Environment variable configuration (IT only needs HOST + PORT)
- Include: Nginx reverse proxy configuration example
- Include: Systemd service file example
- Include: SSL/HTTPS setup guide (optional)
- Include: Troubleshooting common issues
5. Validation
- 5.1 Test backend starts with new config
- 5.2 Test frontend builds with environment variables
- 5.3 Test API connectivity between frontend and backend
- 5.4 Verify all hardcoded values are externalized