feat(observability): host/container/Redis/Qdrant metrics + stack self-monitoring#5380
Conversation
…-monitoring Adds node-exporter (host CPU/mem/disk/network), cAdvisor (per-container resource usage, no Docker socket access), and redis_exporter, wires Qdrant's native /metrics, and scrapes every observability-stack component's own /metrics (Prometheus/Alertmanager/Loki/Tempo/Grafana/OTEL collector) so a degrading piece of the stack itself is no longer invisible. Ships a new Grafana dashboard for all of it. Closes #5366
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #5380 +/- ##
==========================================
- Coverage 94.41% 94.37% -0.04%
==========================================
Files 551 551
Lines 44168 44168
Branches 14632 14632
==========================================
- Hits 41702 41685 -17
- Misses 1791 1808 +17
Partials 675 675
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
|
Tip 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 ✅ Gittensory review result - approve/merge recommendedReview updated: 2026-07-12 15:46:45 UTC
✅ Suggested Action - Approve/Merge
Review summary Nits — 5 non-blocking
Linked issue satisfactionAddressed Review context
Contributor next steps
Signal definitions
[BETA] Chat with GittensoryAsk Gittensory a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://gittensory.aethereal.dev/docs/gittensory-commands 🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by Gittensory, a quiet PR intelligence layer for OSS maintainers.
|
Summary
node-exporter(host CPU/mem/disk/network),cadvisor(per-container CPU/memory/network/disk-IO), andredis-exporter(connected clients/memory/ops/hit-ratio) todocker-compose.ymlunder--profile observability./metrics(--profile qdrant) and adds aobservability-stackself-monitoring job so Prometheus/Alertmanager/Loki/Tempo/Grafana/OTEL-collector watch each other's own/metrics— previously none of them were scraped at all, so a degrading stack component had zero visibility.service.telemetry.metrics.readers, port 8888), distinct from the existing:8889re-exported Claude Code metrics.docker-proxyservice exists specifically because a read-only socket mount doesn't limit the Docker API surface behind it. I tested routing cAdvisor through the existing narrowdocker-proxyfirst (isolateddocker runtests, not touching the live stack); it doesn't give real per-container enumeration even withCONTAINERS/NETWORKS/INFOgranted, so widening that proxy further wasn't worth the added exposure for a labels-only improvement. Containers show by a 12-char cgroup-derived ID (matchesdocker ps's own default width) instead of a friendly compose service name — documented as a tradeoff in the compose file, the dashboard panel descriptions, and the new dashboard's own test.grafana/dashboards/infra-health.json: stack self-health, host (node-exporter), containers (cAdvisor), Redis, and Qdrant panels — every PromQL expression verified against the live Prometheus instance via/api/v1/query..env.example,selfhost-compose-resource-limits.test.ts, andselfhost-observability-config.test.tsfor the 3 new services + new scrape targets; adds a dedicated test file for the new dashboard.Part of #5365. Closes #5366.
Test plan
npm run typechecknpm run test:ci(full local gate, 14985 passed / 12 skipped)npm audit --audit-level=moderate— 0 vulnerabilitiesnode scripts/validate-observability-configs.mjsotelcol-contrib validateagainst the real 0.155.0 image