feat(01-01): Backend FastAPI skeleton + Docker build config

- FastAPI app with SPAStaticFiles catch-all (root_path NOT in constructor)
- config.py with DATA_PATH, PROMPTS_PATH, OUTPUTS_PATH, CAMPAIGNS_PATH, CONFIG_PATH
- Startup lifespan creates data directories automatically
- Health endpoint: GET /api/health -> {"status": "ok"}
- Dockerfile multi-stage: node:22-slim builds React, python:3.12-slim serves API+SPA
- --root-path /postgenerator set in Uvicorn CMD only (avoids Pitfall #4)
- docker-compose.yml: lab-postgenerator-app, proxy_net, named volume for data persistence
- requirements.txt with pinned versions: fastapi[standard]==0.135.1, anthropic==0.84.0
This commit is contained in:
Michele
2026-03-08 01:51:41 +01:00
parent 696b265e4d
commit 50d5708016
9 changed files with 244 additions and 0 deletions

5
requirements.txt Normal file
View File

@@ -0,0 +1,5 @@
fastapi[standard]==0.135.1
anthropic==0.84.0
httpx==0.28.1
python-dotenv==1.2.2
aiofiles==24.1.0