Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| abb30dc3fb | |||
| 70f0d6f57e |
@ -11,7 +11,6 @@ volumes:
|
||||
|
||||
services:
|
||||
|
||||
# POUR AFFICHAGE DASHBOARD
|
||||
grafana:
|
||||
image: grafana/grafana:11.2.0
|
||||
container_name: grafana
|
||||
@ -30,8 +29,12 @@ services:
|
||||
ipv4_address: 192.168.100.10
|
||||
labels:
|
||||
org.label-schema.group: "monitoring"
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost:3000/api/health"]
|
||||
interval: 30s
|
||||
timeout: 5s
|
||||
retries: 3
|
||||
|
||||
# METRICS GATHERER
|
||||
prometheus:
|
||||
image: prom/prometheus:v2.54.1
|
||||
container_name: prometheus
|
||||
@ -52,8 +55,13 @@ services:
|
||||
- grafana-network
|
||||
labels:
|
||||
org.label-schema.group: "monitoring"
|
||||
healthcheck:
|
||||
test: ["CMD", "wget", "http://localhost:9090"]
|
||||
interval: 10s
|
||||
timeout: 15s
|
||||
retries: 10
|
||||
start_period: 40s
|
||||
|
||||
# FOR HOST METRICS
|
||||
nodeexporter:
|
||||
image: prom/node-exporter:v1.8.2
|
||||
container_name: nodeexporter
|
||||
@ -74,7 +82,7 @@ services:
|
||||
labels:
|
||||
org.label-schema.group: "monitoring"
|
||||
|
||||
# FOR DOCKER CONTAINERS
|
||||
|
||||
cadvisor:
|
||||
image: gcr.io/cadvisor/cadvisor
|
||||
container_name: cadvisor
|
||||
@ -92,7 +100,7 @@ services:
|
||||
labels:
|
||||
org.label-schema.group: "monitoring"
|
||||
|
||||
# LOKI FOR LOGS
|
||||
|
||||
loki:
|
||||
image: grafana/loki:latest
|
||||
container_name: loki
|
||||
@ -103,19 +111,22 @@ services:
|
||||
- ./loki/cert:/etc/loki/cert
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
- /etc/timezone:/etc/timezone:ro
|
||||
# environment:
|
||||
command: -config.file=/etc/loki/config.yml -config.expand-env=true
|
||||
networks:
|
||||
- grafana-network
|
||||
healthcheck:
|
||||
test: wget --quiet --tries=1 --output-document=- http://localhost:3100/ready | grep -q -w ready || exit 1
|
||||
start_period: 20s
|
||||
interval: 10s
|
||||
timeout: 1s
|
||||
retries: 12 # try for 2 minutes
|
||||
|
||||
# FOR ALERTS
|
||||
alertmanager:
|
||||
image: prom/alertmanager:v0.20.0
|
||||
container_name: alertmanager
|
||||
volumes:
|
||||
- ./alertmanager:/etc/alertmanager
|
||||
command:
|
||||
#- '--config.file=/etc/alertmanager/config.yml'
|
||||
- '--config.file=/etc/alertmanager/alertmanager.yml'
|
||||
- '--storage.path=/alertmanager'
|
||||
restart: unless-stopped
|
||||
@ -125,6 +136,11 @@ services:
|
||||
- grafana-network
|
||||
labels:
|
||||
org.label-schema.group: "monitoring"
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost:9093/-/ready"]
|
||||
interval: 30s
|
||||
timeout: 5s
|
||||
retries: 3
|
||||
|
||||
pushgateway:
|
||||
image: prom/pushgateway:v1.2.0
|
||||
@ -136,3 +152,8 @@ services:
|
||||
- grafana-network
|
||||
labels:
|
||||
org.label-schema.group: "monitoring"
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost:9091/metrics"]
|
||||
interval: 30s
|
||||
timeout: 5s
|
||||
retries: 3
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user