|
|
|
@@ -11,18 +11,19 @@
|
|
|
|
|
# 0.0.0.0:8188 publish answers on loopback). A bridge-networked prober could
|
|
|
|
|
# reach neither class reliably.
|
|
|
|
|
#
|
|
|
|
|
# WHY the listener binds TWO addresses. The netavark hairpin gap (measured
|
|
|
|
|
# 2026-10-21, cadvisor job comment): a BRIDGE CONTAINER CANNOT DIAL ITS OWN
|
|
|
|
|
# HOST'S LAN IP at all — so a LAN-only bind is unscrapable by Prometheus,
|
|
|
|
|
# whatever the signal-relay law suggests for services containers dial as
|
|
|
|
|
# clients. The podman gateway (169.254.1.2 = host.containers.internal) is the
|
|
|
|
|
# address bridge containers reach same-host targets at, so the exporter binds
|
|
|
|
|
# it explicitly for the scrape rather than relying on loopback-forwarding
|
|
|
|
|
# semantics, and keeps the LAN bind for diagnostics. No public DNS name, no
|
|
|
|
|
# guard chain: internal net only, per the exposure policy. The listen flag is
|
|
|
|
|
# --web.listen-address and it is REPEATABLE, one flag per bind; plain
|
|
|
|
|
# --listen-address does not exist and the exporter exits in 100 ms with
|
|
|
|
|
# "unknown long flag" (live 2026-10-21).
|
|
|
|
|
# WHY the listener binds 127.0.0.1 + LAN. A bridge container CANNOT dial
|
|
|
|
|
# its own host's LAN IP (netavark hairpin gap, measured 2026-10-21), but a
|
|
|
|
|
# bridge container dialing the podman gateway 169.254.1.2 lands on the host
|
|
|
|
|
# LOOPBACK — that is the scrape path, and it needs this exporter to be
|
|
|
|
|
# LISTENING ON LOOPBACK (proved: 200 from the prometheus container to
|
|
|
|
|
# http://169.254.1.2:9115/-/healthy with a loopback bind). The gateway
|
|
|
|
|
# address itself is NOT bindable from the host netns — it exists only
|
|
|
|
|
# inside each rootless netns; binding it dies "bind: cannot assign
|
|
|
|
|
# requested address" (live 2026-10-21). The LAN bind stays for diagnostics.
|
|
|
|
|
# No public DNS name, no guard chain: internal net only, per the exposure
|
|
|
|
|
# policy. The listen flag is --web.listen-address and it is REPEATABLE, one
|
|
|
|
|
# flag per bind; plain --listen-address does not exist and the exporter
|
|
|
|
|
# exits in 100 ms with "unknown long flag" (live 2026-10-21).
|
|
|
|
|
|
|
|
|
|
[Unit]
|
|
|
|
|
Description=Blackbox exporter (HTTP probe prober)
|
|
|
|
@@ -32,9 +33,18 @@ After=network-online.target
|
|
|
|
|
Image=docker.io/prom/blackbox-exporter@sha256:ea1c7aa3ef3f307cd03e85f34abb604478ccb90b567fc690da0cd9776da76b13
|
|
|
|
|
ContainerName=blackbox-exporter
|
|
|
|
|
Network=host
|
|
|
|
|
Exec=/bin/blackbox_exporter --config.file=/etc/blackbox_exporter/config.yml --web.listen-address=192.168.0.143:9115 --web.listen-address=169.254.1.2:9115
|
|
|
|
|
# The image's ENTRYPOINT is /bin/blackbox_exporter itself (proved live
|
|
|
|
|
# 2026-10-21: `podman run IMAGE sh` dies "unexpected sh"), so Exec= carries
|
|
|
|
|
# FLAGS ONLY — repeating the binary makes it a positional arg and kingpin
|
|
|
|
|
# exits "unexpected /bin/blackbox_exporter".
|
|
|
|
|
Exec=--config.file=/etc/blackbox_exporter/config.yml --web.listen-address=127.0.0.1:9115 --web.listen-address=192.168.0.143:9115
|
|
|
|
|
Volume=/opt/blackbox/blackbox.yml:/etc/blackbox_exporter/config.yml:ro
|
|
|
|
|
HealthCmd=/bin/sh -c "wget -q -O /dev/null http://169.254.1.2:9115/-/healthy || exit 1"
|
|
|
|
|
# Plain exec form like every sibling unit. Shell form (`/bin/sh -c "…"`)
|
|
|
|
|
# is passed as one quoted token and quadlet then folds the following
|
|
|
|
|
# --health-interval/--health-retries (and the image name) into the command
|
|
|
|
|
# string — unit died twice that way, live 2026-10-21. wget only; this
|
|
|
|
|
# busybox variant has no curl, and host-network wget answers on loopback.
|
|
|
|
|
HealthCmd=wget -q -O /dev/null http://127.0.0.1:9115/-/healthy
|
|
|
|
|
HealthInterval=30s
|
|
|
|
|
HealthRetries=3
|
|
|
|
|
|
|
|
|
|