-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.test.yml
More file actions
63 lines (54 loc) · 1.31 KB
/
docker-compose.test.yml
File metadata and controls
63 lines (54 loc) · 1.31 KB
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
version: "3.8"
services:
mrroboto:
build:
context: .
dockerfile: Dockerfile
container_name: mrroboto-bot
restart: unless-stopped
# Environment variables for testing (without .env file initially)
environment:
- NODE_ENV=production
- TZ=UTC
- LOG_LEVEL=info
# Mount volumes for persistent data
volumes:
# Persistent storage for data directory (bot's memory and config)
- ./data:/usr/src/app/data
# Persistent storage for logs
- ./logs:/usr/src/app/logs
# Resource limits to prevent runaway processes
deploy:
resources:
limits:
memory: 512M
cpus: "0.5"
reservations:
memory: 256M
cpus: "0.25"
# Network configuration
networks:
- mrroboto-network
# Health check
healthcheck:
test: ["CMD", "node", "-e", "console.log('Health check passed')"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
# Logging configuration
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
# Networks
networks:
mrroboto-network:
driver: bridge
# Volumes (if you prefer named volumes instead of bind mounts)
volumes:
mrroboto-data:
driver: local
mrroboto-logs:
driver: local