prometheus-blackbox/docker-compose.yml

67 lines
1.8 KiB
YAML
Raw Normal View History

2020-01-09 04:29:13 +00:00
version: "3"
services:
prometheus:
image: prom/prometheus:v2.15.2
container_name: prometheus
restart: unless-stopped
command:
- "--config.file=/etc/prometheus/prometheus.yml"
- "--web.console.libraries=/etc/prometheus/console_libraries"
- "--web.console.templates=/etc/prometheus/consoles"
- "--web.enable-lifecycle"
- "--storage.tsdb.path=/prometheus"
- "--storage.tsdb.retention=200h"
networks:
- monitoring
volumes:
- prometheus_data:/prometheus
- ./config/prometheus.yml:/etc/prometheus/prometheus.yml
- ./config/alertrules.yml:/etc/prometheus/alertrules.yml
blackbox:
image: prom/blackbox-exporter:v0.16.0
container_name: blackbox
restart: unless-stopped
command:
- "--config.file=/etc/blackbox/blackbox.yml"
networks:
- monitoring
volumes:
- ./config/blackbox.yml:/etc/blackbox/blackbox.yml
alertmanager:
image: prom/alertmanager:v0.20.0
container_name: alertmanager
restart: unless-stopped
command:
- "--config.file=/etc/alertmanager/alertmanager.yml"
- "--storage.path=/alertmanager"
networks:
- monitoring
volumes:
- ./config/alertmanager.yml:/etc/alertmanager/alertmanager.yml
grafana:
image: grafana/grafana:6.5.2
container_name: grafana
restart: unless-stopped
networks:
- monitoring
volumes:
- grafana_data:/var/lib/grafana
- ./config/grafana/provisioning:/etc/grafana/provisioning
environment:
- GF_SECURITY_ADMIN_USER=${GRAFANA_USER:?err}
- GF_SECURITY_ADMIN_PASSWORD=${GRAFANA_PASSWORD:?err}
- GF_USERS_ALLOW_SIGN_UP=false
ports:
- 3000:3000
networks:
monitoring: {}
volumes:
prometheus_data: {}
grafana_data: {}