-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
72 lines (66 loc) · 1.76 KB
/
docker-compose.yml
File metadata and controls
72 lines (66 loc) · 1.76 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
64
65
66
67
68
69
70
71
72
version: '3.8'
services:
tradingbot:
build:
context: .
dockerfile: Dockerfile
container_name: tradingbot
volumes:
- ./config:/home/tradingbot/config
- ./logs:/home/tradingbot/logs
environment:
- LOG_LEVEL=${LOG_LEVEL:-info}
- SIMULATION_MODE=${SIMULATION_MODE:-true}
- API_KEY=${API_KEY}
- API_SECRET=${API_SECRET}
restart: unless-stopped
# Uncomment if you need to expose the web interface
# ports:
# - "8080:8080"
networks:
- trading_network
# Add Redis for caching and message queue
redis:
image: redis:7-alpine
container_name: tradingbot_redis
volumes:
- redis_data:/data
networks:
- trading_network
restart: unless-stopped
# Add Prometheus for metrics
prometheus:
image: prom/prometheus:latest
container_name: tradingbot_prometheus
volumes:
- ./prometheus:/etc/prometheus
- prometheus_data:/prometheus
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--storage.tsdb.path=/prometheus'
- '--web.console.libraries=/usr/share/prometheus/console_libraries'
- '--web.console.templates=/usr/share/prometheus/consoles'
networks:
- trading_network
restart: unless-stopped
# Add Grafana for visualization
grafana:
image: grafana/grafana:latest
container_name: tradingbot_grafana
volumes:
- grafana_data:/var/lib/grafana
- ./grafana/provisioning:/etc/grafana/provisioning
environment:
- GF_SECURITY_ADMIN_PASSWORD=${GRAFANA_PASSWORD:-admin}
networks:
- trading_network
restart: unless-stopped
depends_on:
- prometheus
volumes:
redis_data:
prometheus_data:
grafana_data:
networks:
trading_network:
driver: bridge