-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
54 lines (52 loc) · 1.54 KB
/
docker-compose.yml
File metadata and controls
54 lines (52 loc) · 1.54 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
networks:
demo:
driver: bridge
services:
prometheus:
image: prom/prometheus:v3.10.0
container_name: prometheus
restart: always
volumes:
- ./Prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
ports:
- 9090:9090
command:
- "--config.file=/etc/prometheus/prometheus.yml"
- "--web.enable-lifecycle" # Enable reload of configuration
- "--enable-feature=native-histograms"
- "--web.enable-otlp-receiver" # Enable OTLP receiver
networks:
- demo
healthcheck:
test:
[
"CMD",
"wget",
"--quiet",
"--tries=1",
"--spider",
"http://localhost:9090/-/healthy",
]
interval: 10s
timeout: 5s
start_period: 3s
retries: 5
grafana:
image: grafana/grafana:12.4.1
container_name: grafana
environment:
TZ: Europe/Lisbon
GF_AUTH_ANONYMOUS_ENABLED: true # Allow anonymous access
GF_AUTH_ANONYMOUS_ORG_ROLE: Admin # Set the role for anonymous users to Admin
GF_AUTH_BASIC_ENABLED: false # Disable basic auth
ports:
- 3000:3000
volumes:
- ./Grafana/data-source.yml:/etc/grafana/provisioning/datasources/data-source.yml # Data source configurations
- ./Grafana/dashboards:/etc/grafana/provisioning/dashboards # Folder containing dashboards
- ./Grafana/dashboard.yml:/etc/grafana/provisioning/dashboards/dashboard.yml # Dashboard configurations
networks:
- demo
depends_on:
prometheus:
condition: service_healthy