Prometheus exporter that scrapes the Bulletin of the Atomic Scientists Doomsday Clock value and exposes it as a gauge of seconds to midnight. A background scraper caches the value with a configurable TTL, serves stale values with a degradation gauge on upstream failure, and retries with exponential backoff.
  • Go 87.9%
  • Dockerfile 6.2%
  • Shell 4.8%
  • Makefile 1.1%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Damián Búho 2cf143e4b1
All checks were successful
published / release-tag (push) Successful in 2s
published / runner-is-ready (push) Successful in 6s
published / gpg-is-ready (push) Successful in 7s
published / signing-is-ready (push) Successful in 7s
published / projectfile-is-valid (push) Successful in 6s
published / source-is-compliant (push) Successful in 9s
published / documentation-passes-lint (push) Successful in 13s
published / projectfile-is-ok (push) Successful in 8s
published / source-is-tested (push) Successful in 24s
published / source-is-secure (push) Successful in 39s
published / source-passes-lint (push) Successful in 57s
published / binaries-are-built (arm64, linux) (push) Successful in 5s
published / binaries-are-built (amd64, linux) (push) Successful in 5s
published / binaries-are-built (riscv64, linux) (push) Successful in 5s
published / binaries-are-signed (push) Has been skipped
published / image-is-built (amd64) (push) Successful in 1m7s
published / image-has-sbom (amd64) (push) Has been skipped
published / container-is-verified (amd64) (push) Successful in 47s
published / image-is-secure (amd64) (push) Successful in 1m41s
published / image-is-published (dockerhub) (push) Successful in 7s
published / image-is-published (kiota) (push) Successful in 12s
published / release-is-published (push) Has been skipped
published / go-install-is-ok (push) Has been skipped
published / release-notes-are-published (push) Has been skipped
published / published (push) Successful in 1s
build(workflows): add configuration-names-check
2026-11-10 22:38:09 -03:00
.compose fix: drop o9s leftovers, keep O9S_* env names as deprecated fallback 2026-09-30 17:09:06 -03:00
.container feat!: drop deprecated O9S_* env fallback 2026-09-30 17:13:26 -03:00
.forgejo/workflows build(workflows): add configuration-names-check 2026-11-10 22:38:09 -03:00
.github/workflows build(workflows): add configuration-names-check 2026-11-10 22:38:09 -03:00
.grafana/dashboards feat(grafana): add a Doomsday Clock dashboard 2026-11-10 00:34:40 -03:00
.makefile chore(makefile): sync m6e submodules 2026-11-10 22:06:05 -03:00
.scripts build: remove the unused gh-release script 2026-10-15 20:26:49 -03:00
docs docs(makefile): update help documentation 2026-11-10 22:06:09 -03:00
LICENSES chore: init 2026-08-15 13:48:06 -03:00
.claudeignore chore: sorting for claudeignore 2026-09-13 12:49:05 -03:00
.containerignore build: ignore .worktrees (oci/docker) 2026-09-29 23:59:20 -03:00
.dockerignore build: ignore .worktrees (oci/docker) 2026-09-29 23:59:20 -03:00
.gitattributes chore: clean j2 from attributes 2026-09-14 00:36:47 -03:00
.gitignore build: ignore .worktrees 2026-09-29 23:56:18 -03:00
.gitmodules build: hard .gitmodules before big refactoring of m6e 2026-09-02 18:40:12 -03:00
.yamllint feat(forge): declare the account as forge org with a bare flatpath 2026-09-17 22:26:03 -03:00
AGENTS.md feat: export average age of nuclear launch authorities 2026-11-10 00:18:02 -03:00
AI_POLICY.md chore(docs): prevent user data from triggering textlint 2026-08-19 23:23:57 -03:00
CITATION.cff chore(version): 0.10.0 2026-11-10 01:06:06 -03:00
CLAUDE.md chore: init 2026-08-15 13:48:06 -03:00
CODE_OF_CONDUCT.md docs: cleanup code of conduct 2026-08-18 02:17:53 -03:00
CODEOWNERS chore: init 2026-08-15 13:48:06 -03:00
CONTRIBUTING.md chore: regenerate contributing 2026-09-30 06:39:42 -03:00
Dockerfile feat: export average age of nuclear launch authorities 2026-11-10 00:18:02 -03:00
go.mod fix(deps): bump github.com/klauspost/compress to v1.20.3 2026-11-06 15:47:02 -03:00
go.sum fix(deps): bump github.com/klauspost/compress to v1.20.3 2026-11-06 15:47:02 -03:00
go.sum.license chore: init 2026-08-15 13:48:06 -03:00
leaders.go feat: export median age of nuclear launch authorities 2026-11-10 00:31:37 -03:00
leaders_test.go feat: export median age of nuclear launch authorities 2026-11-10 00:31:37 -03:00
lefthook.yaml build(workflows): support for staged lint 2026-11-06 15:47:01 -03:00
LICENSE chore: init 2026-08-15 13:48:06 -03:00
main.go feat: export average age of nuclear launch authorities 2026-11-10 00:18:02 -03:00
main_test.go feat: export median age of nuclear launch authorities 2026-11-10 00:31:37 -03:00
Makefile chore: init 2026-08-15 13:48:06 -03:00
projectfile.yaml chore(version): 0.10.0 2026-11-10 01:06:06 -03:00
README.md chore(docs): regen readme 2026-11-10 00:50:30 -03:00
SECURITY.md docs(security): show the fingerprint of the reporting key 2026-10-15 23:30:22 -03:00
SUPPORT.md chore(docs): reenable codeberg 2026-09-18 14:36:03 -03:00

Español · Українська

Doomsday Clock Exporter

Prometheus exporter that scrapes the Bulletin of the Atomic Scientists Doomsday Clock value and exposes it as a gauge of seconds to midnight. A background scraper caches the value with a configurable TTL, serves stale values with a degradation gauge on upstream failure, and retries with exponential backoff.

Stand with Ukraine Projectfile inside License Cosign ClamAV scanned PRs welcome REUSE compliance

Project status Last commit on kiota.ch Last commit on Codeberg Last commit on GitHub

Publish pipeline on GitHub Vulnerability audit on GitHub Dependency freshness on GitHub Analysis sweep on GitHub

Publish pipeline on kiota.ch Vulnerability audit on kiota.ch Dependency freshness on kiota.ch Analysis sweep on kiota.ch

Features

  • Cached scraping with graceful degradation
  • Environment variable configuration
  • Service-specific healthcheck
  • Average and median age of the people with launch authority
  • Self-observability metrics

It also inherits the features of B19 / Ubuntu — see Features for the full list.

Quick Start

Save this as compose.yaml:

---
services:
  doomsday-clock-exporter:
    image: docker.io/damianbuho/doomsday-clock-exporter:latest
    ports:
      - "8080:8080"
    cap_drop: [ALL]
    security_opt: [no-new-privileges:true]
    restart: unless-stopped

Then start it with docker compose up --detach.

What this provides

  • Service exporter — listens on 8080 (metrics) — Prometheus metrics endpoint
  • Executable doomsday-clock-exporter — command doomsday-clock-exporter
  • Container image ghcr.io/damian-buho/doomsday-clock-exporter:latest
  • Container image damianbuho/doomsday-clock-exporter:latest

Installation

Container image

Pull the published container image:

Pull from GHCR — linux/amd64, linux/arm64, linux/riscv64

docker pull ghcr.io/damian-buho/doomsday-clock-exporter:latest

Pull from DockerHub — linux/amd64

docker pull damianbuho/doomsday-clock-exporter:latest

Stable releases also publish X.Y.Z, X.Y and X tags — pull the precision you want to pin.

If the registries above are unreachable, pull from the origin instead:

Pull from Kiota — linux/amd64

docker pull kiota.ch/damian-buho/doomsday-clock-exporter:latest

Prebuilt binary

Download the prebuilt binary for your platform from GitHub Releases:

mkdir -p ~/.local/bin
curl --fail --location --output ~/.local/bin/doomsday-clock-exporter https://github.com/damian-buho/doomsday-clock-exporter/releases/latest/download/doomsday-clock-exporter-linux-$(uname -m)
chmod +x ~/.local/bin/doomsday-clock-exporter
~/.local/bin/doomsday-clock-exporter --help

Published for: linux/amd64, linux/arm64, linux/riscv64

To uninstall, delete that one file: rm ~/.local/bin/doomsday-clock-exporter.

Usage

Run the service in the background, publishing its ports:

From GHCR

docker run --detach --publish 8080:8080/tcp ghcr.io/damian-buho/doomsday-clock-exporter:latest

From DockerHub

docker run --detach --publish 8080:8080/tcp damianbuho/doomsday-clock-exporter:latest

Then check that it answers:

curl http://localhost:8080/metrics

Building

Clone the repository with its submodules:

git clone --recurse-submodules https://codeberg.org/damian-buho/doomsday-clock-exporter doomsday-clock-exporter && cd doomsday-clock-exporter

Build the container image locally:

make container-build

Run make with no arguments for the default target; run make help to list every target.

For the local dev loop, make dev-container brings up the dev-container.

Pipeline entry points:

  • make analyzed — Run the heavy analysis sweep (mutation testing, benchmarks)
  • make audited — Re-scan the pinned dependencies and published artifacts for new vulnerabilities
  • make check-outdated — Report every pinned dependency that lags upstream
  • make release-is-ready — Run the pseudo-CI pipeline locally — build, test and scan, without publishing

Policies

License

This project is licensed under MIT — see the LICENSE file for details.