Skip to content

Commit

Permalink
docker: add node-exporter for monitoring
Browse files Browse the repository at this point in the history
  • Loading branch information
vincentbernat committed Nov 21, 2023
1 parent 493854a commit ec70171
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
11 changes: 11 additions & 0 deletions docker/docker-compose-monitoring.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,17 @@ services:
- traefik.http.routers.prometheus.rule=PathPrefix(`/prometheus`)
- traefik.http.services.prometheus.loadbalancer.server.port=9090

node-exporter:
image: prom/node-exporter:v1.7.0
restart: unless-stopped
volumes:
- /proc:/host/proc:ro
- /sys:/host/sys:ro
command:
- --path.procfs=/host/proc
- --path.sysfs=/host/sys
- --no-collector.filesystem

kafka-jmx-exporter:
image: bitnami/jmx-exporter:0
restart: unless-stopped
Expand Down
9 changes: 9 additions & 0 deletions docker/prometheus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,15 @@ scrape_configs:
values:
- com.docker.compose.project=akvorado
- com.docker.compose.service=kafka-jmx-exporter
- job_name: node-exporter
docker_sd_configs:
- host: unix:///var/run/docker.sock
refresh_interval: 30s
filters:
- name: label
values:
- com.docker.compose.project=akvorado
- com.docker.compose.service=node-exporter
- job_name: akvorado
metrics_path: /api/v0/metrics
docker_sd_configs:
Expand Down

0 comments on commit ec70171

Please sign in to comment.