Repository navigation
feat(countme): replace bluefin-countme with a daily projectbluefin-countme ping - #1205
Conversation
Homebrew no longer ships `tremor-runtime` (`https://formulae.brew.sh/api/formula/tremor-runtime.json` → 404), so "Validate Brewfiles" fails on every open PR at `cncf.Brewfile:265` (e.g. runs for #1205 and `fix/ai-tools-align-agent-mode`). This removes the entry and its duplicated `# Tremor` comment. No other file references it. Verification: `just check-brewfiles` no longer reports `tremor-runtime`; `bats tests/test_validate_brewfiles.bats` passes. Assisted-by: Claude Opus 5.5 via pi Co-authored-by: Jorge Castro <jorge@projectbluefin.io>
|
I read the whole diff at 66f4ba5 and ran the new suite. 1. The new service has none of the old sandboxing. 2. CI does not run the new tests. The Unit Tests workflow (run 36063166584) has no step for 3. It conflicts with #1225. Both PRs fix the same Small one: |
hanthor
left a comment
There was a problem hiding this comment.
A few things before this can go in:
projectbluefin-countme.service: the hardening from the old unit is gone (ProtectSystem=strict,ProtectHome,PrivateTmp,NoNewPrivileges,RestrictAddressFamilies,SystemCallFilter). This is a root service that parses JSON and talks to the network, so please restore it.bootc statusworks underProtectSystem=strict.- Scope: reporting widens from Dakota to Utah, and the script ships in
shared/, so theimage-nameprefix check is the only gate. That's a telemetry/privacy change that needs explicit maintainer sign-off, and docs.projectbluefin.io/analytics should be updated at the same time. projectbluefin-countme:24: ifimage-flavoris missing, the payload contains the literalnull. Please default it.- The timer's
Wants=network.targetdoes nothing in a timer unit. Minor. - This deletes
tests/test_bluefin_countme.bats, which #1249 adds to CI, and the replacement suite isn't registered inunit-tests.yml. Please coordinate with #1249.
|
Status update on CountMe ping migration:
Awaiting author updates on service hardening, null fallback, and unit-test registration. |
|
@hanthor @Danathar Pushed commit 88e10f9 addressing the review findings:
All 7 suite tests plus registration checks pass. Ready for your review. |
hanthor
left a comment
There was a problem hiding this comment.
Thanks. The sandbox block is back and matches the old unit, image-flavor defaults to main, Wants=network.target is gone, and the new suite is in unit-tests.yml. All good.
Still open:
testis red.tests/test_suite_registration.batsfails because theJustfiletest recipe still runstests/test_bluefin_countme.bats(line 14 once merged with main; it came in with #1192 after your branch point). Please rebase and drop that line.- Coordinate with #1249: it adds the same deleted suite at
unit-tests.yml:156-157. - Utah scope: I don't see a maintainer sign-off in the thread yet, and docs.projectbluefin.io/analytics still describes Dakota-only reporting. That needs an explicit OK plus the docs update before this merges.
hanthor
left a comment
There was a problem hiding this comment.
Thanks for dropping the Justfile line in af2a8fb. Unfortunately #1225 went in right after and added bats tests/test_bluefin_countme.bats back (main Justfile:48), so this is conflicting again.
Still open:
- Rebase on main and drop
Justfile:48again. #1249 is about to land with aRun bats (bluefin-countme)step (unit-tests.yml:163-164), so drop that step as well when you rebase. - Utah scope: this is a policy question, not a code problem. There's still no maintainer sign-off in the thread for widening reporting from Dakota to Utah, and docs.projectbluefin.io/analytics still says Dakota only. It stays open until a maintainer agrees here and the docs change is ready to go with it.
The code side is otherwise good.
af2a8fb to
53537d6
Compare
|
Rebased cleanly on main, and 53537d6 drops the stale |
|
Rebased onto main and cleared the test-registration conflict hanthor flagged:
Verified locally: Left open, exactly as hanthor noted: the Utah scope is a telemetry/privacy change, not a code fix. It needs an explicit maintainer sign-off in this thread plus the
|
Danathar
left a comment
There was a problem hiding this comment.
Re-checked at 53537d6. All three points from my review are fixed: the service has the old sandboxing back line for line, unit-tests.yml now runs the new suite, and the Justfile conflict with #1225 is resolved. CI is green.
On the Utah scope: I'm fine with CountMe covering Utah as well as Dakota, since the ping only carries image-name/flavor:stream. Before this merges, please update docs.projectbluefin.io/analytics to say Dakota and Utah, so the public page matches what the images do.
Danathar
left a comment
There was a problem hiding this comment.
Re-checked the one commit since my approval (53537d6..a5e0ef2). It adds ConditionPathExists=! checks for /etc/systemd/system/bluefin-countme.timer and .service, so a mask of the old units (what docs.projectbluefin.io/analytics tells people to run today) still stops the new service; systemd-analyze condition fails for a path symlinked to /dev/null and passes for a missing one. tests/test_suite_registration.bats and tests/test_projectbluefin_countme.bats pass (14/14), and the required checks (validate, test, both builds, Trivy) are green; the E2E run was still going when I looked. My earlier note still stands: the public analytics page still describes weekly metalink reporting, so please update it to match the daily Dakota and Utah ping before this merges.
castrojo
left a comment
There was a problem hiding this comment.
Author follow-up at a5e0ef2.
I re-checked hanthor's code points and all of them hold at head:
projectbluefin-countme.service:21-28has the old sandbox block unchanged (PrivateTmp,ProtectSystem=strict,ProtectHome,NoNewPrivileges,RestrictAddressFamilies,SystemCallFilter=@system-service @mount).projectbluefin-countme:24falls back tomainwhenimage-flavoris missing.Wants=network.targetis gone.tests/test_projectbluefin_countme.batsis registered in.github/workflows/unit-tests.yml:163-164andJustfile:50.- Neither the
Justfilenorunit-tests.ymlstill references the deletedtest_bluefin_countme.bats. The branch point already includes #1249, and a trial merge with current main (12e3114) is clean and leaves no stale references.
One new fix in a5e0ef2. docs.projectbluefin.io/analytics tells users to opt out with systemctl mask --now bluefin-countme.timer bluefin-countme.service. The replacement units have new names, so those masks would stop applying and opted-out Dakota systems would start reporting again. projectbluefin-countme.service:12-14 now also skips when /etc/systemd/system/bluefin-countme.timer or .service exists. That path is where systemctl mask puts its /dev/null symlink. I checked the semantics with a transient systemd-run --user unit: with ConditionPathExists=! pointing at a /dev/null symlink the unit was skipped, and without the symlink it ran. docs/skills/image-registry.md:122-125 lists the preserved opt-outs.
Local checks: bats tests/test_projectbluefin_countme.bats tests/test_suite_registration.bats gives 14/14 ok. systemd-analyze verify on the unit reports only the host-missing /usr/libexec binary. At a5e0ef2 validate, both image builds, unit tests, Trivy and PR E2E are green.
Still open: the Utah scope, which is a policy question. Danathar has OK'd Dakota plus Utah. The docs.projectbluefin.io/analytics update has not been opened yet. It needs to say Dakota and Utah, describe the daily /v1/ping payload (image-name/flavor:stream, no cohort buckets), and give the new opt-out (systemctl mask --now projectbluefin-countme.timer). @hanthor, your re-review is the one still outstanding once that docs PR is up.
|
Here is where each of hanthor's review points (R5319615531, R5323541980, R5323665571) is fixed at head a5e0ef2:
Required checks are green at a5e0ef2. Danathar approved at this head (R5327343284). Still open: the Utah telemetry scope. This is a maintainer policy decision, not a code change. Once it's decided, the docs.projectbluefin.io/analytics update will be opened in projectbluefin/documentation and paired with this merge. That page still describes the weekly castrojo is the author, so castrojo's approval doesn't count. This still needs a second approval from someone other than castrojo. |
|
The /analytics update requested in review is up: projectbluefin/documentation#1355. It covers Dakota + Utah scope, the daily |
|
Status check at head |
Pairs with projectbluefin/common#1205, which replaces the weekly bluefin-countme metalink client with a daily /v1/ping from Dakota and Utah images. States the payload, cadence, storage, and the new opt-out; notes that masks of the previous units still apply. Assisted-by: Claude Opus via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
correctness
- low —
system_files/shared/usr/libexec/projectbluefin-countme:19runsbootc status --json 2>/dev/nulland treats any empty result as "no booted image" (:20exit 0). Ifbootc statusfails for another reason — e.g. under the unit'sProtectSystem=strict/SystemCallFilter=@system-service @mountsandbox (projectbluefin-countme.service:24-28), which the PR body says was not the environment the client was tested in — the failure is indistinguishable from a live ISO, nothing is logged, and the machine is silently never counted, every 3h, forever. The replaced script loggedbootc status failed: …to the journal. Dropping the2>/dev/null(stderr already goes to the journal) keeps the exit-0 behaviour but makes that state observable.
No findings from: security, intent-alignment, style, docs-currency.
Confidence: 5/5 (safe)
— hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88
…untme ping
Dakota and Utah images now send at most one anonymous
{"image": "<image-name>/<image-flavor>:<stream>"} per day to
countme.projectbluefin.io/v1/ping. The stream comes from the booted bootc
ref; other images (Bluefin Classic, LTS) exit before any network call.
Timer and service follow upstream eos-phone-home; a failed send exits 0
and the next run retries. The previous opt-out files still block the
service; the documented opt-out is masking the timer.
Removes the weekly /metalink client (bluefin-countme) and its tests.
Assisted-by: Claude Opus 5.5 via pi
…unit tests - restore systemd security hardening directives on projectbluefin-countme.service - drop vestigial Wants=network.target on timer unit - default image-flavor to 'main' when empty or null - register test_projectbluefin_countme.bats in unit-tests.yml
docs.projectbluefin.io/analytics tells users to opt out with `systemctl mask --now bluefin-countme.timer bluefin-countme.service`. The replacement units have new names, so those masks no longer applied and opted-out Dakota systems would start reporting again. Skip the service when either old unit is masked in /etc/systemd/system. Assisted-by: Claude via omp Signed-off-by: castrojo <castrojo@users.noreply.github.com>
a5e0ef2 to
138e16e
Compare
There was a problem hiding this comment.
Read at head 138e16e. Ran tests/test_projectbluefin_countme.bats + test_suite_registration.bats locally: 14/14 pass.
correctness
- low —
projectbluefin-countme.timer:6dropsOnCalendar/PersistentforOnUnitInactiveSec=3h, whileprojectbluefin-countme.service:6-14keepsCondition*gates. systemd only re-armsOnUnitInactiveSecfrom the service's inactive-enter timestamp; a start that is skipped by a failed condition never transitions state, so the timer goeselapsedand does not fire again until reboot (systemd/systemd#23696). The opt-out/ostree-bootedconditions are static per boot so that's harmless, butConditionDirectoryNotEmpty=/home(service:7) is not: a first boot with an empty/home(user created after first boot) skips the ping and never retries that boot. Undercount only, andeos-phone-homehas the same gap, but worth knowing since the PR body says "the next run retries". If you want the retry guarantee, move the/homecheck into the script (exit 0) so the unit actually runs. - info (limit of review) —
projectbluefin-countme:19now makesbootc status --jsonthe only stream source (old script preferred/run/ublue-os/booted-image), underProtectSystem=strict+SystemCallFilter=@system-service @mount(service:24-28). The body says the client was exercised in a Fedora container, not under this sandbox on a booted Dakota/Utah; I could not verify it either. Onejournalctl -u projectbluefin-countmeon a real deploy would close this.
No findings from: security, intent-alignment, style, docs-currency.
Confidence: 5/5 (safe)
— hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88
Pairs with projectbluefin/common#1205, which replaces the weekly bluefin-countme metalink client with a daily /v1/ping from Dakota and Utah images. States the payload, cadence, storage, and the new opt-out; notes that masks of the previous units still apply. Assisted-by: Claude Opus via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…untme ping (projectbluefin#1205) Replaces the weekly `/metalink` client (`bluefin-countme`) with `projectbluefin-countme`, reporting to the live `countme.projectbluefin.io/v1/ping` (projectbluefin/documentation#1347). **What it sends:** at most once per 24h, `{"image": "<image-name>/<image-flavor>:<stream>"}`, e.g. `dakota-nvidia/nvidia:testing`. No hardware fields, no identifiers. **Scope:** `system_files/shared` reaches every consumer, so the script exits before any network call unless `image-info.json` `image-name` starts with `dakota` or `utah`. Bluefin Classic and LTS never report (bats-tested). **Stream:** booted ref tag from `bootc status` (`stable`/`testing`, else `unknown`); digest suffix stripped; never the baked `image-tag`. No booted bootc image ⇒ no report. **Timer/service:** upstream `eos-phone-home` units (`OnActiveSec=0`, `OnUnitInactiveSec=3h`, `AccuracySec=30m`, `ConditionDirectoryNotEmpty=/home`, `Type=simple`). Deviations: `After/Wants=network-online.target` (upstream uses a NetworkManager dispatcher hook), `StateDirectory=` (upstream: tmpfiles), `ConditionPathExists=/run/ostree-booted`, enabled via preset + `timers.target.wants` (upstream: a `.path` unit). A failed send exits 0 and the next run retries. **Opt-out:** `systemctl mask --now projectbluefin-countme.timer`. The previous opt-out files (`/etc/projectbluefin/countme/disabled`, `/etc/bluefin-countme-opt-out`, `/etc/dakota-countme/disabled`) still block the service, so nobody who opted out is opted back in. **Rollout notes:** - Dakota picks this up only when `elements/bluefin/common.bst` moves past it; that bump also carries common#1121 (ChairLift rebrand), which Dakota's `files/chairlift/install.sh` currently rejects. - Utah picks it up with its next `COMMON_IMAGE_SHA` bump; its `image-info.json` has `image-name: utah`. - Unverified: that the Dakota/Utah live ISOs report no booted bootc image. ISO owners can check with `bootc status --json` in the live session. **Verification:** new `tests/test_projectbluefin_countme.bats` 7/7 (registered in the Justfile); all 38 registered bats suites pass; pytest 115/115; `just check` passes; shellcheck and `systemd-analyze verify` clean; `pre-commit` hooks pass (skill catalog `--check` run with `jsonschema` installed). The client was also run in a Fedora container against the Worker on an empty local D1. Assisted-by: Claude Opus 5.5 via pi --------- Signed-off-by: castrojo <castrojo@users.noreply.github.com> Co-authored-by: Jorge Castro <jorge@projectbluefin.io> Co-authored-by: castrojo <castrojo@users.noreply.github.com>
Replaces the weekly
/metalinkclient (bluefin-countme) withprojectbluefin-countme, reporting to the livecountme.projectbluefin.io/v1/ping(projectbluefin/documentation#1347).What it sends: at most once per 24h,
{"image": "<image-name>/<image-flavor>:<stream>"}, e.g.dakota-nvidia/nvidia:testing. No hardware fields, no identifiers.Scope:
system_files/sharedreaches every consumer, so the script exits before any network call unlessimage-info.jsonimage-namestarts withdakotaorutah. Bluefin Classic and LTS never report (bats-tested).Stream: booted ref tag from
bootc status(stable/testing, elseunknown); digest suffix stripped; never the bakedimage-tag. No booted bootc image ⇒ no report.Timer/service: upstream
eos-phone-homeunits (OnActiveSec=0,OnUnitInactiveSec=3h,AccuracySec=30m,ConditionDirectoryNotEmpty=/home,Type=simple). Deviations:After/Wants=network-online.target(upstream uses a NetworkManager dispatcher hook),StateDirectory=(upstream: tmpfiles),ConditionPathExists=/run/ostree-booted, enabled via preset +timers.target.wants(upstream: a.pathunit). A failed send exits 0 and the next run retries.Opt-out:
systemctl mask --now projectbluefin-countme.timer. The previous opt-out files (/etc/projectbluefin/countme/disabled,/etc/bluefin-countme-opt-out,/etc/dakota-countme/disabled) still block the service, so nobody who opted out is opted back in.Rollout notes:
elements/bluefin/common.bstmoves past it; that bump also carries common#1121 (ChairLift rebrand), which Dakota'sfiles/chairlift/install.shcurrently rejects.COMMON_IMAGE_SHAbump; itsimage-info.jsonhasimage-name: utah.bootc status --jsonin the live session.Verification: new
tests/test_projectbluefin_countme.bats7/7 (registered in the Justfile); all 38 registered bats suites pass; pytest 115/115;just checkpasses; shellcheck andsystemd-analyze verifyclean;pre-commithooks pass (skill catalog--checkrun withjsonschemainstalled). The client was also run in a Fedora container against the Worker on an empty local D1.Assisted-by: Claude Opus 5.5 via pi