-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
42 lines (41 loc) · 927 Bytes
/
docker-compose.yml
File metadata and controls
42 lines (41 loc) · 927 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
services:
sakura-summary-bot:
build: .
container_name: sakura-bot
user: "root:root"
restart: unless-stopped
ports:
- "${WEBUI_PORT:-8080}:8080"
environment:
- TZ=Asia/Shanghai
env_file:
- data/.env
volumes:
# 持久化整个 data 目录 - 避免单文件挂载错误
- ./data:/app/data
# 健康检查
healthcheck:
test: ["CMD", "python", "-c", "import sys; sys.exit(0)"]
interval: 30s
timeout: 10s
retries: 3
start_period: 60s
# 资源限制
deploy:
resources:
limits:
memory: 1024M
reservations:
memory: 256M
# 日志配置
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
# 网络配置
networks:
- sakura-network
networks:
sakura-network:
driver: bridge