mirror of
https://github.com/lintsinghua/DeepAudit.git
synced 2026-10-25 18:11:29 +08:00
- 将前端代码移动到 frontend/ 目录 - 将后端代码移动到 backend/ 目录 - 更新 .gitignore 以包含 Python 和前端构建产物 - 修复 LLM JSON 解析问题,增强错误处理 - 修复前端配置默认值,改为从后端获取 - 删除 AdminDashboard 中的数据库信息和统计卡片 - 完善系统配置管理,支持从后端获取默认配置
53 lines
1.1 KiB
YAML
53 lines
1.1 KiB
YAML
version: '3.8'
|
|
|
|
services:
|
|
db:
|
|
image: postgres:15-alpine
|
|
volumes:
|
|
- postgres_data:/var/lib/postgresql/data
|
|
environment:
|
|
- POSTGRES_USER=postgres
|
|
- POSTGRES_PASSWORD=postgres
|
|
- POSTGRES_DB=xcodereviewer
|
|
ports:
|
|
- "5432:5432"
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U postgres"]
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 5
|
|
|
|
backend:
|
|
build:
|
|
context: ./backend
|
|
volumes:
|
|
- ./backend:/app
|
|
ports:
|
|
- "8000:8000"
|
|
environment:
|
|
- DATABASE_URL=postgresql+asyncpg://postgres:postgres@db:5432/xcodereviewer
|
|
- SECRET_KEY=changethisdevsecret
|
|
- ALGORITHM=HS256
|
|
- ACCESS_TOKEN_EXPIRE_MINUTES=30
|
|
depends_on:
|
|
db:
|
|
condition: service_healthy
|
|
command: uvicorn app.main:app --host 0.0.0.0 --port 8000 --reload
|
|
|
|
frontend:
|
|
build:
|
|
context: ./frontend
|
|
volumes:
|
|
- ./frontend:/app
|
|
- /app/node_modules
|
|
ports:
|
|
- "5173:5173"
|
|
environment:
|
|
- VITE_API_BASE_URL=/api
|
|
depends_on:
|
|
- backend
|
|
command: npm run dev -- --host
|
|
|
|
volumes:
|
|
postgres_data:
|