-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.monitoring.yml
More file actions
57 lines (53 loc) · 1.55 KB
/
docker-compose.monitoring.yml
File metadata and controls
57 lines (53 loc) · 1.55 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
# Prometheus + Grafana monitoring stack for HyperCache metrics.
#
# Usage:
# docker compose -f docker-compose.monitoring.yml up -d
#
# Then open:
# Grafana: http://localhost:3001 (admin / admin123)
# Prometheus: http://localhost:9090
#
# The pre-provisioned dashboard "HyperCache — Prometheus Metrics" is
# auto-loaded and uses the Prometheus datasource. Select your node(s)
# from the dropdown at the top.
#
# Prerequisites: HyperCache node(s) must be running and exposing
# the /metrics endpoint (HTTP port, default 9080).
services:
prometheus:
image: prom/prometheus:v2.51.0
container_name: hypercache-prometheus
ports:
- "9090:9090"
volumes:
- ./prometheus.yml:/etc/prometheus/prometheus.yml:ro
- prometheus_data:/prometheus
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--storage.tsdb.retention.time=7d'
networks:
- monitoring
grafana:
image: grafana/grafana:10.2.0
container_name: hypercache-grafana-prom
ports:
- "3001:3000"
environment:
- GF_SECURITY_ADMIN_PASSWORD=admin123
- GF_USERS_ALLOW_SIGN_UP=false
volumes:
- grafana_prom_data:/var/lib/grafana
- ./grafana/provisioning/dashboards:/etc/grafana/provisioning/dashboards:ro
- ./grafana/provisioning/datasources/prometheus.yml:/etc/grafana/provisioning/datasources/prometheus.yml:ro
depends_on:
- prometheus
networks:
- monitoring
volumes:
prometheus_data:
driver: local
grafana_prom_data:
driver: local
networks:
monitoring:
driver: bridge