docs: 生成项目文档并优化项目结构
- 生成完整的 README.md 项目文档 - 统一图片路径为相对引用 - 完善 .gitignore 配置,添加常见忽略项 - 清理未使用的临时文件和图片资源 - 删除废弃的脚本文件
This commit is contained in:
+9
-47
@@ -3,59 +3,21 @@ version: '3.8'
|
||||
services:
|
||||
postgres:
|
||||
image: postgres:15-alpine
|
||||
restart: unless-stopped
|
||||
container_name: yunhaifinance-postgres
|
||||
environment:
|
||||
POSTGRES_USER: ${DB_USER:-postgres}
|
||||
POSTGRES_PASSWORD: ${DB_PASSWORD:-changeme}
|
||||
POSTGRES_DB: ${DB_NAME:-company_finance}
|
||||
ports:
|
||||
- "5432:5432"
|
||||
- "10052:5432"
|
||||
volumes:
|
||||
- postgres_data:/var/lib/postgresql/data
|
||||
- yunhaifinance-postgres-data:/var/lib/postgresql/data
|
||||
- ./backend/migrations:/docker-entrypoint-initdb.d
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U ${DB_USER:-postgres}"]
|
||||
interval: 10s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
backend:
|
||||
build:
|
||||
context: ./backend
|
||||
dockerfile: Dockerfile
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "${BACKEND_PORT:-3000}:3000"
|
||||
environment:
|
||||
NODE_ENV: production
|
||||
PORT: 3000
|
||||
DB_HOST: postgres
|
||||
DB_PORT: 5432
|
||||
DB_NAME: ${DB_NAME:-company_finance}
|
||||
DB_USER: ${DB_USER:-postgres}
|
||||
DB_PASSWORD: ${DB_PASSWORD:-changeme}
|
||||
JWT_SECRET: ${JWT_SECRET:-please-change-this-secret}
|
||||
CORS_ORIGIN: ${CORS_ORIGIN:-}
|
||||
TENCENT_SECRET_ID: ${TENCENT_SECRET_ID:-}
|
||||
TENCENT_SECRET_KEY: ${TENCENT_SECRET_KEY:-}
|
||||
COS_BUCKET: ${COS_BUCKET:-}
|
||||
COS_REGION: ${COS_REGION:-}
|
||||
depends_on:
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
volumes:
|
||||
- upload_data:/app/uploads
|
||||
|
||||
frontend:
|
||||
build:
|
||||
context: ./frontend
|
||||
dockerfile: Dockerfile
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "${FRONTEND_PORT:-80}:80"
|
||||
depends_on:
|
||||
- backend
|
||||
networks:
|
||||
- yunhaifinance-network
|
||||
|
||||
volumes:
|
||||
postgres_data:
|
||||
upload_data:
|
||||
yunhaifinance-postgres-data:
|
||||
|
||||
networks:
|
||||
yunhaifinance-network:
|
||||
Reference in New Issue
Block a user