homelab-codex-ws/services/fleet-prometheus/prometheus.yml

40 lines
1.5 KiB
YAML
Raw Normal View History

# fleet-prometheus — fleet liveness source of truth.
#
# Deliberately SEPARATE from the home `prom` on PIHA (LAN-only). The `fleet`
# external label and the `fleet-` job naming make it unambiguous in every
# scraped series that this instance monitors the distributed fleet, not the
# home LAN. This file is SECRET-FREE by contract — never inline tokens here
# (the home prom embedding a plaintext HAOS token is the anti-pattern we avoid).
global:
scrape_interval: 15s
external_labels:
fleet: "homelab-codex"
# alerting:
# # Alertmanager wiring is added in a separate step (fleet liveness alerting).
# alertmanagers: []
# rule_files:
# # Liveness rules (e.g. up == 0 for: 5m) are added in a separate step.
# - "rules/*.yml"
scrape_configs:
# Self-monitoring — Prometheus scrapes its own /metrics. Bridged container
# listens on 0.0.0.0:9090, so localhost resolves inside the container.
- job_name: "prometheus"
static_configs:
- targets: ["localhost:9090"]
# First and only fleet target for this scaffold: the VPS-local node_exporter,
# which runs network_mode: host and listens on the host's :9100. Reached via
# the host-gateway alias declared in docker-compose.yml.
- job_name: "fleet-node"
static_configs:
- targets: ["host.docker.internal:9100"]
labels:
node: "vps"
# NOTE: Tailscale fleet targets (100.x node_exporters across SATURN, SOLARIA,
# PIHA, CHELSTY) are added in a separate step — not part of this scaffold.