83 lines
2.4 KiB
YAML
83 lines
2.4 KiB
YAML
##############################################
|
|
# This is my monitoring stack
|
|
##############################################
|
|
name: monitoring-stack
|
|
|
|
networks:
|
|
monitoring:
|
|
|
|
services:
|
|
##############################################
|
|
# Graphite
|
|
# URL: https://graphite.readthedocs.io/en/stable/
|
|
# Docker Hub: https://hub.docker.com/r/graphiteapp/graphite-statsd
|
|
##############################################
|
|
graphite:
|
|
image: graphiteapp/graphite-statsd:latest
|
|
environment:
|
|
- GRAPHITE_TIME_ZONE=${TZ:-UTC}
|
|
volumes:
|
|
- ${BASE_DIR:-.}/Graphite/Data:/opt/graphite/storage
|
|
- ${BASE_DIR:-.}/Graphite/Config:/opt/graphite/conf
|
|
- ${BASE_DIR:-.}/Graphite/Statsd_Config:/opt/statsd/config
|
|
- ${BASE_DIR:-.}/Graphite/Logs:/var/log
|
|
networks:
|
|
- monitoring
|
|
ports:
|
|
- 3080:80
|
|
- 2003-2004:2003-2004
|
|
- 2023-2024:2023-2024
|
|
- 8225:8125/udp
|
|
- 8226:8126
|
|
restart: unless-stopped
|
|
logging:
|
|
driver: loki
|
|
options:
|
|
loki-url: "http://localhost:3100/loki/api/v1/push"
|
|
max-size: "200m"
|
|
|
|
##############################################
|
|
# Loki
|
|
# Docs: https://grafana.com/docs/loki/latest/
|
|
# GitHub: https://github.com/grafana/loki
|
|
# Dokcer Hub: https://hub.docker.com/r/grafana/loki
|
|
##############################################
|
|
loki:
|
|
image: grafana/loki:3.3.2
|
|
command: -config.file=/etc/loki/loki-config.yaml
|
|
volumes:
|
|
- ${BASE_DIR:-.}/Loki/Config/loki-config.yaml:/etc/loki/loki-config.yaml
|
|
- ${BASE_DIR:-.}/Loki/Data:/data/loki
|
|
networks:
|
|
- monitoring
|
|
ports:
|
|
- "3100:3100"
|
|
restart: unless-stopped
|
|
logging:
|
|
driver: loki
|
|
options:
|
|
loki-url: "http://localhost:3100/loki/api/v1/push"
|
|
max-size: "200m"
|
|
|
|
|
|
##############################################
|
|
# Prometheus
|
|
# Docs: https://prometheus.io/docs/prometheus/latest/
|
|
# Docker Hub: https://hub.docker.com/r/prom/prometheus
|
|
##############################################
|
|
prometheus:
|
|
image: prom/prometheus:v3.1.0
|
|
command: --web.enable-lifecycle --config.file=/etc/prometheus/prometheus.yml
|
|
volumes:
|
|
- ${BASE_DIR:-.}/Prometheus/Config:/etc/prometheus
|
|
- ${BASE_DIR:-.}/Prometheus/Data:/prometheus
|
|
networks:
|
|
- monitoring
|
|
ports:
|
|
- 9000:9090
|
|
restart: unless-stopped
|
|
logging:
|
|
driver: loki
|
|
options:
|
|
loki-url: "http://localhost:3100/loki/api/v1/push"
|
|
max-size: "200m"
|