Skip to main content

frisch

Deployment version visibility for the Nectar Research Cloud.

Nectar services are deployed three ways: ArgoCD applications on kubernetes, docker containers on puppet-managed VMs, and debian packages on VMs and bare metal, each in a test and a prod environment (test is upgraded first). frisch collects the deployed version of every service in both environments, records when each environment changed to that version, and serves a dashboard that shows the version matrix and per-service history, making promotion lag from test to prod visible at a glance.

How it works

collectors -> Observation -> ingest (single writer) -> MariaDB -> API -> SPA

Three collectors, one normalised record:

  • argocd (git-declared): walks the history of the per-environment ArgoCD apps repos, parsing each Application CRD's spec.source.targetRevision (and spec.sources for multi-source apps). Change dates are exact git commit times; the full history is backfillable.
  • puppet (git-declared): walks the puppet site repos (one per environment) and the shared hieradata repo, scanning hiera *::image_tag keys and their # renovate: annotations. Also exact, backfillable.
  • deb (live): queries the PuppetDB package inventory in each environment for configured package names/patterns. Package versions are not in git, so frisch's own records are the only durable history; change times are intervals ("changed between X and Y"), bounded by the collection interval.

Versions are opaque strings everywhere -- they are never compared or ordered, only equality-checked and timestamped.

Running

pip install -e '.[test]'
frisch db upgrade                       # create/upgrade the schema
frisch-collect --backfill               # first run: full git history
frisch-collect                          # incremental (the CronJob entry point)
frisch-web                              # serve the dashboard on :8080
frisch show matrix                      # the same table, in a terminal

Configuration is layered: FRISCH_* environment variables over a YAML config file (--config, FRISCH_CONFIG, ~/.config/frisch/frisch.yaml or /etc/frisch/frisch.yaml) over defaults. See etc/frisch.yaml.sample. For local development, point the repo urls at your existing checkouts and use the default SQLite database.

The SPA lives in frontend/ (vite + React); npm run dev proxies /api to a locally running frisch-web. In the container image the built bundle is served by the backend.

Deployment prerequisites

  • A database and user on the MariaDB cluster in each environment.
  • A read-only deploy key for the five source repos.
  • PuppetDB package inventory enabled (package_inventory_enabled on agents) and network/auth access to the PuppetDB endpoints; until then the deb source reports itself unavailable on the status page.

Development

tox            # unit tests and lint
tox -e pep8    # lint only
tox -e frontend  # build the SPA (needs npm)

Releases use reno for release notes. Contributions go through gerrit; use conventional commits and git commit -s.

Release files for frisch 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for frisch 0.2.0
File Size Uploaded
frisch-0.2.0.tar.gz 82.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for frisch 0.2.0
File Interpreter ABI Platform
frisch-0.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 124.4 kB

Release files / frisch-0.2.0.tar.gz

Download URL frisch-0.2.0.tar.gz
Size 82.9 kB
Tags Source
SHA-256 checksum
How to use checksums
38f2257a29bfeb2f9da7c78266c1589bbfe8d714022706838e14ef0c8510f012
BLAKE2b-256 checksum
How to use checksums
74a8bb88548050f5d821471dcbf7c90f09831503950f004face28ac7f1c2db1c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.3

Release files / frisch-0.2.0-py3-none-any.whl

Download URL frisch-0.2.0-py3-none-any.whl
Size 41.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
bdc381771e220719f80462e68f3b7a9ce9262c61116c6c3678510cf98ce08224
BLAKE2b-256 checksum
How to use checksums
48c29e711f784fbc98a6502ad6088dd8c321865f0abb5df3559a49e62abf2abe
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.3

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files

0.1.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page