From fa355e1ebc4b0bf2509acf64be3352d15b849a2e Mon Sep 17 00:00:00 2001 From: Philipp Glaum Date: Mon, 17 Jul 2023 09:41:37 +0200 Subject: [PATCH] node-exporter for system metrics --- docker-compose.yml | 12 ++++++++++++ prometheus.yaml | 4 ++++ 2 files changed, 16 insertions(+) diff --git a/docker-compose.yml b/docker-compose.yml index 4464310..909f928 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -82,6 +82,18 @@ services: clone_config: condition: service_completed_successfully + node_exporter: + image: quay.io/prometheus/node-exporter:latest + command: + - '--path.rootfs=/host' + network_mode: host + pid: host + restart: unless-stopped + volumes: + - '/:/host:ro,rslave' + networks: + - traefik-public + volumes: grafana-data: prometheus-data: diff --git a/prometheus.yaml b/prometheus.yaml index 7c882e0..1e336c9 100644 --- a/prometheus.yaml +++ b/prometheus.yaml @@ -7,3 +7,7 @@ scrape_configs: static_configs: - targets: - "traefik:8080" + - job_name: node_exporter + static_configs: + - targets: + - "node_exporter:9100"