Sign inSign up

jmrplens/ghchronicle

By jmrplens

•Updated 3 days ago

Collects every metric GitHub exposes about an account and keeps it with the date it happened

Image
API management
Developer tools
Data science
0

1.3K

jmrplens/ghchronicle repository overview

⁠ghchronicle

Collects everything GitHub will tell you about an account, and keeps it with the date it happened.

GitHub answers questions about the present and almost none about the past. Traffic is a rolling fourteen days. The activity feed keeps the last three hundred events. Read notifications vanish. Job logs go at ninety days. ghchronicle sweeps those surfaces on a schedule and writes every observation as a point stamped with the date the thing happened, so a year from now the question "how fast were we merging in July" still has an answer.

Ninety-one measurements, thirty-four collectors, ten destinations (InfluxDB, PostgreSQL, Elasticsearch, Graphite, Loki, Prometheus, OpenTelemetry, Telegraf, a file, stdout) and five generated Grafana dashboards.

⁠Run it

docker run -d --name ghchronicle \
  -v /etc/ghchronicle/config.yaml:/config.yaml:ro \
  -v ghchronicle-state:/var/lib/ghchronicle \
  -e GITHUB_TOKEN \
  -p 9605:9605 \
  jmrplens/ghchronicle -config /config.yaml

One sweep and exit, instead of the schedule: add -once. Mount the state volume in that mode too; it is what makes the second run cheap.

The image is distroless, runs as 65532 and ships no shell. It needs a personal access token with read scopes: the automatic GITHUB_TOKEN of a workflow is not enough, because traffic needs push access and Dependabot alerts need security_events.

⁠Tags

v1.0.0 and latest, for linux/amd64 and linux/arm64. The same image is on ghcr.io/jmrplens/ghchronicle.

Tag summary

Content type

Image

Digest

sha256:890ab1a1f…

Size

6.9 MB

Last updated

3 days ago

docker pull jmrplens/ghchronicle