forked from kj89/cosmos_node_monitoring
-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
123 lines (115 loc) · 2.89 KB
/
docker-compose.yml
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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
version: "3.5"
volumes:
prometheus_data: {}
grafana_data: {}
alerta_db: {}
networks:
cosmos-monitoring:
services:
prometheus:
image: prom/prometheus:latest
container_name: prometheus
volumes:
- type: volume
source: prometheus_data
target: /prometheus
- type: bind
source: ./prometheus
target: /etc/prometheus
read_only: true
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--storage.tsdb.path=/prometheus'
- '--web.enable-lifecycle'
ports:
- 9090:9090
networks:
- cosmos-monitoring
restart: always
# default login credentials: admin/admin
grafana:
image: grafana/grafana:latest
env_file: ./grafana/grafana.conf
container_name: grafana
volumes:
- type: volume
source: grafana_data
target: /var/lib/grafana
- ./grafana/datasource.yml:/etc/grafana/provisioning/datasources/datasource.yml
- ./grafana/dashboards:/etc/grafana/provisioning/dashboards
ports:
- 9999:3000
networks:
- cosmos-monitoring
restart: always
alerta_db:
image: postgres:11
container_name: alerta_db
networks:
- cosmos-monitoring
volumes:
- type: volume
source: alerta_db
target: /var/lib/postgresql/data
environment:
POSTGRES_DB: cosmos_monitoring
POSTGRES_USER: admin
POSTGRES_PASSWORD: admin
hostname: 'alerta_db'
restart: always
alerta:
image: alerta/alerta-web:latest
container_name: alerta
networks:
- cosmos-monitoring
ports:
- 8083:8083
depends_on:
- alerta_db
volumes:
- type: bind
source: ./alerta/alertad.conf
target: /app/alertad.conf
read_only: true
environment:
- DATABASE_URL=postgres://postgres:postgres@alerta_db:5432/monitoring
- PLUGINS=reject,blackout
hostname: 'alerta'
restart: always
alertmanager:
image: prom/alertmanager:latest
container_name: alertmanager
networks:
- cosmos-monitoring
ports:
- 9093:9093
volumes:
- type: bind
source: ./prometheus/alert_manager
target: /etc/alertmanager
read_only: true
command: [
'--config.file=/etc/alertmanager/alertmanager.yml',
'--log.level=debug',
]
hostname: 'alertmanager'
restart: always
alertmanager-bot:
container_name: alertmanager-bot
command:
- '--alertmanager.url=http://alertmanager:9093'
- '--log.level=info'
- '--store=bolt'
- '--bolt.path=/data/bot.db'
- "--telegram.admin=${TELEGRAM_ADMIN}"
- "--telegram.token=${TELEGRAM_TOKEN}"
image: metalmatze/alertmanager-bot:0.4.3
networks:
- cosmos-monitoring
ports:
- 8080:8080
hostname: 'alertmanager-bot'
restart: always
volumes:
- ./data:/data
- ./default.tmpl:/templates/default.tmpl