muster-ping-collector

command
v0.321.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 2, 2026 License: MIT Imports: 12 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

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)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL