2021-05-19 10:28:16 -04:00
|
|
|
version: '2'
|
|
|
|
services:
|
|
|
|
|
|
|
|
prometheus:
|
|
|
|
container_name: prometheus
|
|
|
|
image: prom/prometheus
|
|
|
|
ports:
|
|
|
|
- 9090:9090
|
|
|
|
command: '--config.file=/etc/prometheus/prometheus.yml'
|
|
|
|
volumes:
|
|
|
|
- ./docker/prometheus/prometheus.docker.yml:/etc/prometheus/prometheus.yml
|
|
|
|
- ./docker/prometheus/prometheus_rules.yml:/etc/prometheus/prometheus_rules.yml
|
|
|
|
- ./docker/volumes/prometheus_data:/prometheus
|
|
|
|
depends_on:
|
|
|
|
- node-exporter
|
|
|
|
- haproxy
|
2021-09-07 15:09:45 -05:00
|
|
|
- flask_metrics
|
2021-05-19 10:28:16 -04:00
|
|
|
external_links:
|
|
|
|
- haproxy
|
2021-09-07 15:09:45 -05:00
|
|
|
- flask_metrics
|
2021-05-19 10:28:16 -04:00
|
|
|
|
|
|
|
node-exporter:
|
|
|
|
container_name: node-exporter
|
|
|
|
image: prom/node-exporter
|
|
|
|
ports:
|
|
|
|
- 9100:9100
|
|
|
|
|
|
|
|
grafana:
|
|
|
|
container_name: grafana
|
2021-06-14 20:31:24 -06:00
|
|
|
image: grafana/grafana:7.5.7
|
2021-05-19 10:28:16 -04:00
|
|
|
environment:
|
|
|
|
- GF_SECURITY_ADMIN_PASSWORD=pass
|
|
|
|
depends_on:
|
|
|
|
- prometheus
|
|
|
|
ports:
|
|
|
|
- 3000:3000
|
|
|
|
volumes:
|
|
|
|
- ./docker/volumes/grafana_data:/var/lib/grafana
|
2021-09-07 15:09:45 -05:00
|
|
|
- ./docker/grafana/datasources/datasource.docker.yaml:/etc/grafana/provisioning/datasources/datasource.docker.yaml
|
2021-05-19 10:28:16 -04:00
|
|
|
- ./docker/grafana/dashboards/:/etc/grafana/provisioning/dashboards/
|
|
|
|
external_links:
|
|
|
|
- prometheus
|
2021-09-07 15:09:45 -05:00
|
|
|
flask_metrics:
|
|
|
|
container_name: flask_metrics
|
|
|
|
build:
|
|
|
|
context: .
|
|
|
|
dockerfile: docker/flask_metrics/Dockerfile
|
|
|
|
environment:
|
|
|
|
- FLASK_APP=flask_metrics:app
|
|
|
|
- MONGODB_SERVER=db_mongo
|
|
|
|
- MONGODB_PORT=29019
|
|
|
|
ports:
|
|
|
|
- 5000:5000
|
|
|
|
volumes:
|
|
|
|
- ./flask_metrics:/srv/newsblur
|
|
|
|
depends_on:
|
|
|
|
- db_mongo
|
|
|
|
external_links:
|
|
|
|
- db_mongo
|
|
|
|
command: flask run --host=0.0.0.0
|