fix(monitoring): Linux-only exporters behind host-metrics profile; loki 3.5 key; prometheus joins shared network

- node-exporter + cadvisor need Linux rootfs mounts (fail on Docker
  Desktop) — moved to 'host-metrics' profile; VPS command updated
- loki 3.5: ingestion_burstsize_mb → ingestion_burst_size_mb
- prometheus joins erp_shared so job 'erp-api' resolves (verified: up=1)
This commit is contained in:
MMD
2026-09-19 01:02:09 +03:30
parent e1495afee9
commit 948727d73b
2 changed files with 9 additions and 1 deletions
+8
View File
@@ -82,6 +82,7 @@ services:
- prometheus_data:/prometheus - prometheus_data:/prometheus
networks: networks:
- monitoring - monitoring
- shared
restart: unless-stopped restart: unless-stopped
grafana: grafana:
@@ -130,10 +131,12 @@ services:
restart: unless-stopped restart: unless-stopped
# -------------------------------------------------------------- exporters -- # -------------------------------------------------------------- exporters --
# Linux-host only (see cadvisor note): local runs skip it via the profile.
node-exporter: node-exporter:
image: prom/node-exporter:v1.9.1 image: prom/node-exporter:v1.9.1
container_name: monitoring-node-exporter container_name: monitoring-node-exporter
mem_limit: 32m mem_limit: 32m
profiles: ["host-metrics"]
command: command:
- --path.rootfs=/host - --path.rootfs=/host
volumes: volumes:
@@ -155,10 +158,15 @@ services:
- shared - shared
restart: unless-stopped restart: unless-stopped
# Linux-host only: the rootfs bind mounts fail on Docker Desktop (Windows/macOS).
# VPS: docker compose -f monitoring/docker-compose.monitoring.yml --env-file .env \
# --profile host-metrics up -d
# Local: started WITHOUT the profile — per-container metrics are simply absent.
cadvisor: cadvisor:
image: gcr.io/cadvisor/cadvisor:v0.49.1 image: gcr.io/cadvisor/cadvisor:v0.49.1
container_name: monitoring-cadvisor container_name: monitoring-cadvisor
mem_limit: 128m mem_limit: 128m
profiles: ["host-metrics"]
privileged: true privileged: true
devices: devices:
- /dev/kmsg - /dev/kmsg
+1 -1
View File
@@ -28,7 +28,7 @@ limits_config:
# Keep the log store bounded — this box shares 8 GB RAM / limited disk. # Keep the log store bounded — this box shares 8 GB RAM / limited disk.
retention_period: 14d retention_period: 14d
ingestion_rate_mb: 4 ingestion_rate_mb: 4
ingestion_burstsize_mb: 8 ingestion_burst_size_mb: 8
max_query_series: 500 max_query_series: 500
compactor: compactor: