Skip to content

REQ 038

sergio velderrain edited this page Nov 9, 2026 · 1 revision

REQ-038: Ubuntu register-runner phase achieves functional parity with Windows register-runner; cross-checks the real GitHub API (status+labels), not just the registration command's own exit code

Requirement

The Ubuntu-LabVIEW VM family shall support a register-runner provisioning phase achieving functional parity with the Windows family's own register-runner phase (vm/windows-labview/provision-windows-guest.py + Register-WindowsRunner.ps1): registers a provisioned VM as a GitHub Actions self-hosted runner over SSH (no interactive console session required), using a dedicated, non-privileged local service account for the runner's systemd service, and -- per REQ-020's own established discipline, after a real past incident where a Windows register-runner self-reported success while the runner had actually registered under the wrong name -- independently cross-checks the real GitHub API afterward rather than trusting the registration command's own exit code alone.

Rationale

Before this session, Ubuntu had no runner-registration automation at all (only the Windows family did), which blocked treating "VM creation succeeds" as a symmetric, equally-meaningful release precondition across both platforms (the operator's stated expectation driving this requirement). Building genuine parity first, rather than silently settling for an asymmetric/weaker Ubuntu milestone, was a deliberate operator decision.

Fit Criterion

A fresh or already-provisioned Ubuntu-LabVIEW VM, given a runner-registration PAT, a target repository, a runner name, labels, and a dedicated service-account name, ends with: a running systemd service for the registered runner; a real gh api repos/<target>/actions/runners entry for that exact name with status: "online" and all expected labels (self-hosted, Linux, X64, plus the supplied custom labels); and the supplied PAT file shredded (not merely deleted) from the guest before the phase ends, matching REQ-017's existing credential-cleanup discipline.

Verification

Verified (live): real workflow_dispatch proof against a genuine, freshly-built disposable VM (register-runner-proof-ubuntu-20261107, upstream run 42403330593) -- the registered runner (register-runner-proof-ubuntu) was independently confirmed via gh api repos/svelderrainruiz/projectbuddy/actions/runners showing status: "online" with exactly the expected labels (self-hosted, Linux, X64, register-runner-proof), not merely the phase's own exit code. Three real bugs were found and fixed during this live-dispatch process, each its own follow-up commit: (1) the host orchestrator never set SSH_ASKPASS/SSH_ASKPASS_REQUIRE, unlike complete-activation.sh, causing every ssh/scp call to fail with Permission denied; (2) gh api --jq does not support jq's own --arg flag the way the standalone jq CLI does; (3) a re-registration ordering bug -- config.sh remove refuses to run (Uninstall service first) while a prior run's systemd service is still installed, so the existing stop/uninstall logic had to move before the remove attempt, not after it. The disposable test runner was deregistered and the temporary RUNNER_REGISTRATION_PAT secret removed immediately after.

Source

Software-Requirements-Specification

Priority

High

TestID

TEST-038

TestArtifact

Live workflow_dispatch proof, upstream run 42403330593, runner independently confirmed online via gh api repos/svelderrainruiz/projectbuddy/actions/runners

CodeRef

vm/ubuntu-labview/install-actions-runner.sh, complete-runner-registration.sh

Status

Verified (live)

Clone this wiki locally