No description
  • Python 66%
  • HTML 26.3%
  • CSS 5.9%
  • Shell 1%
  • Dockerfile 0.8%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Gilles Fritz 39d1ed002a
All checks were successful
ci / test (push) Successful in 1m3s
ci / docker (push) Successful in 28s
ci / deploy (push) Successful in 6s
Send publish reports to Argus from the release job (#7)
Closes #6

Monitoring plan, phase 5 rollout, same as the pilots argus/backend#45 and argus/frontend#35.

## Changes (`.forgejo/workflows/ci.yml`)
- New step "Collect publish details for Argus": `ARGUS_ARTIFACT` = `<image:tag>|<compressed bytes>|<package page>`, the size being the sum of the layers of the linux/amd64 manifest (`docker buildx imagetools inspect --raw` + jq); `/tmp/dependencies.txt` = `pip freeze` inside the pushed image (empty on failure).
- Both publish-release calls (numbered release, devel snapshot) get `ARGUS_UPLOAD_TOKEN: ${{ secrets.ARGUS_UPLOAD_TOKEN }}` and `--artifact "$ARGUS_ARTIFACT" --dependencies /tmp/dependencies.txt`. A failed upload only warns, the release itself is unaffected.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

https://claude.ai/code/session_014BSmBtGWeFBD9z4mYm9SjA
Reviewed-on: #7
2026-10-30 08:14:12 +00:00
.forgejo/workflows Send publish reports to Argus from the release job (#7) 2026-10-30 08:14:12 +00:00
config Purge automatique des instances mortes depuis longtemps 2026-09-29 00:51:40 +02:00
deploy Translate README.md and deploy/README.md to English 2026-09-29 00:57:51 +02:00
docs Apply the Vieux Hibou brand kit to the dashboard 2026-10-15 20:21:22 +02:00
instances Apply the Vieux Hibou brand kit to the dashboard 2026-10-15 20:21:22 +02:00
.env.example Premier jet : serveur central vieuxhibou 2026-09-29 00:06:21 +02:00
.gitignore Migrate onto Argus for test/coverage reporting 2026-10-16 13:19:03 +02:00
.pylintrc Migrate to tox, switch ruff to pylint+autopep8+bandit, add coverage 2026-10-13 13:53:31 +02:00
docker-entrypoint.sh Premier jet : serveur central vieuxhibou 2026-09-29 00:06:21 +02:00
Dockerfile Update python Docker tag to v3.15 (#2) 2026-10-19 05:40:12 +00:00
LICENSE Premier jet : serveur central vieuxhibou 2026-09-29 00:06:21 +02:00
manage.py Premier jet : serveur central vieuxhibou 2026-09-29 00:06:21 +02:00
pyproject.toml Migrate to tox, switch ruff to pylint+autopep8+bandit, add coverage 2026-10-13 13:53:31 +02:00
README.md Migrate onto Argus for test/coverage reporting 2026-10-16 13:19:03 +02:00
renovate.json Add renovate.json 2026-10-18 22:20:58 +00:00
requirements-dev.txt Migrate to tox, switch ruff to pylint+autopep8+bandit, add coverage 2026-10-13 13:53:31 +02:00
requirements.txt Update dependency Django to v6 (#4) 2026-10-20 07:47:14 +00:00
tox.ini Migrate onto Argus for test/coverage reporting 2026-10-16 13:19:03 +02:00

vieuxhibou

CI Coverage Tests License: GPL v3

Central server for the small vieuxhibou structured-logging ecosystem: receives the registration and heartbeat of every service instance (vieuxhibou-django, vieuxhibou-gin), and offers a single dashboard to view and hot-change the level of any of their loggers — without restarting any service.

This repo is the server. The two repos above are the client libraries that register with it from each project.

How it works

  • Each service instance (a drh container, poulpinou-worker, etc.) registers here on startup (POST /api/instances/register), then sends a periodic heartbeat (POST /api/instances/<id>/heartbeat) with the current state of all its Python/slog loggers.
  • The dashboard (GET /) lists these instances, grouped by service, with their loggers and a form to change the level of any of them. An instance with no recent heartbeat (VIEUXHIBOU_STALE_AFTER_SECONDS, 90s by default) is shown greyed out rather than silently going stale.
  • Changing a level from the dashboard (POST /instances/<pk>/loggers/<name>/set-level/) doesn't write anything here: it calls back into the instance's own PATCH /vieuxhibou/loggers/<name>/ API (its self_url, supplied at registration) — the source of truth always stays the process itself, this server is only a cache of what it last reported.

Authentication

Two separate mechanisms, no user accounts anywhere in this app:

  • The dashboard (human, browser): no application-level check. Access is entirely delegated to Traefik's shared authentik@file middleware (same mechanism as Grafana/mailpit/RabbitMQ on this server) — see config/settings/base.py.
  • The register/heartbeat/set-level API (machine to machine): a single shared token (VIEUXHIBOU_SHARED_TOKEN), the same value configured here and on every client — deliberately simple for v1, a per-service token could follow if the need arises.

Local development

python3 -m venv .venv && source .venv/bin/activate
pip install -r requirements-dev.txt
python manage.py migrate
python manage.py runserver
pip install tox
tox             # tous les environnements (py315, lint, format-check, bandit)
tox -e py315    # tests unitaires (pytest) + couverture seule
tox -e lint     # pylint (+ pylint-django)
tox -e format   # autopep8 --in-place
tox -e bandit   # analyse de sécurité statique

Deployment

See deploy/README.md.

License

GPLv3, see LICENSE -- an application, not a library meant to be imported elsewhere (unlike vieuxhibou-django/-gin, which are LGPLv3), so no reason to avoid the GPL here.