Documentation
¶
Overview ¶
Command muster-ping-collector receives muster's anonymous usage ping (docs/usage-ping.md) and serves aggregate counts of it. It is a separate, tiny service; muster itself never runs it. It lives in this repository so anyone can read exactly what is received and kept (internal/pingcollector).
POST /v1/ping a heartbeat: strict JSON (usageping.Payload.Validate),
at most usageping.MaxBody bytes; 204 when kept.
GET /v1/stats aggregates for the last ?days=N (1-90, default 30):
installs and active hosts per day, by version and deploy
mode. Needs `Authorization: Bearer $MUSTER_PING_STATS_TOKEN`;
with no token set it is off (404).
GET /v1/stats/page the same numbers as one HTML table, behind the same
token (no script, nothing loaded from elsewhere).
GET /healthz ok.
It keeps one row per install id, kind and UTC day — the payload's fields and nothing about the request: no address is read, stored or logged, and no request is logged at all. Rows older than 180 days are deleted.
Environment:
DATABASE_URL Postgres for the one table it creates (required)
MUSTER_PING_LISTEN listen address (default :8080)
MUSTER_PING_STATS_TOKEN bearer token for /v1/stats and /v1/stats/page ("" = both off)