2025-12-10 18:33:37 +08:00
|
|
|
services:
|
2025-12-17 21:40:18 +08:00
|
|
|
doc_ai:
|
|
|
|
|
build: .
|
|
|
|
|
container_name: doc_ai
|
|
|
|
|
ports:
|
|
|
|
|
- "8024:8024"
|
|
|
|
|
volumes:
|
|
|
|
|
- ./config:/app/config
|
|
|
|
|
- ./logs:/app/logs
|
|
|
|
|
networks:
|
|
|
|
|
- backend
|
|
|
|
|
depends_on:
|
|
|
|
|
mysql:
|
|
|
|
|
condition: service_healthy
|
|
|
|
|
redis:
|
|
|
|
|
condition: service_started
|
|
|
|
|
command: ["-env", "dev"]
|
|
|
|
|
restart: always
|
|
|
|
|
|
2025-12-10 18:33:37 +08:00
|
|
|
mysql:
|
|
|
|
|
image: mysql:8.0
|
|
|
|
|
container_name: mysql
|
|
|
|
|
environment:
|
2025-12-17 21:40:18 +08:00
|
|
|
MYSQL_ROOT_PASSWORD: texpixel#pwd123!
|
|
|
|
|
MYSQL_DATABASE: doc_ai
|
|
|
|
|
MYSQL_USER: texpixel
|
|
|
|
|
MYSQL_PASSWORD: texpixel#pwd123!
|
2025-12-10 18:33:37 +08:00
|
|
|
ports:
|
2025-12-17 21:40:18 +08:00
|
|
|
- "3006:3306"
|
2025-12-10 18:33:37 +08:00
|
|
|
volumes:
|
2025-12-17 21:40:18 +08:00
|
|
|
- mysql_data:/var/lib/mysql
|
2025-12-10 18:33:37 +08:00
|
|
|
networks:
|
|
|
|
|
- backend
|
2025-12-17 21:40:18 +08:00
|
|
|
healthcheck:
|
|
|
|
|
test: ["CMD", "mysqladmin", "ping", "-h", "localhost", "-uroot", "-ptexpixel#pwd123!"]
|
|
|
|
|
interval: 5s
|
|
|
|
|
timeout: 5s
|
|
|
|
|
retries: 10
|
|
|
|
|
start_period: 30s
|
2025-12-10 18:33:37 +08:00
|
|
|
restart: always
|
|
|
|
|
|
|
|
|
|
redis:
|
|
|
|
|
image: redis:latest
|
|
|
|
|
container_name: redis
|
2025-12-17 21:40:18 +08:00
|
|
|
command: redis-server --requirepass "yoge@123321!"
|
2025-12-10 18:33:37 +08:00
|
|
|
ports:
|
2025-12-17 21:40:18 +08:00
|
|
|
- "6079:6379"
|
2025-12-10 18:33:37 +08:00
|
|
|
networks:
|
|
|
|
|
- backend
|
|
|
|
|
restart: always
|
|
|
|
|
|
|
|
|
|
volumes:
|
|
|
|
|
mysql_data:
|
|
|
|
|
# 持久化MySQL数据卷
|
|
|
|
|
driver: local
|
|
|
|
|
|
|
|
|
|
networks:
|
|
|
|
|
backend:
|
|
|
|
|
driver: bridge
|