From f15857bdf79f4cef9a28e6f1a573ca7cdd83b932 Mon Sep 17 00:00:00 2001 From: Geno Roupsky <185580+groupsky@users.noreply.github.com> Date: Mon, 16 Nov 2026 13:05:16 +0200 Subject: [PATCH] ci: ignore messages about the runner's own systemd units The "example units" job failed on main: the runner's newer systemd warns about its own units in /usr/lib/systemd/system (CPUAccounting= removed), and the check failed on any extra line. Ignore lines about the runner's units, and check that systemd loaded our three services. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/ci.yml | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7c83e59..faff10b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -85,10 +85,23 @@ jobs: run: | set -eu for f in contrib/examples/*/*.sh; do sh -n "$f"; done - # The binary is not installed here; every other message fails. + # The binary is not installed here. Messages about the runner's + # own units (/usr/lib/systemd/, /etc/systemd/) are not ours. Our + # unit files show with their absolute checkout path, so this + # filter never hides them. Every other message fails. out="$(systemd-analyze verify --man=no contrib/systemd/* 2>&1 || true)" echo "$out" - if echo "$out" | grep -v "Command /usr/local/bin/pullgate is not executable" | grep -q .; then + # The "not executable" line of each service shows that systemd + # really loaded our units. + n="$(echo "$out" | grep -c -E '^pullgate-(apply@[^ ]*|listen|run@[^ ]*)\.service: Command /usr/local/bin/pullgate is not executable' || true)" + if [ "$n" -ne 3 ]; then + echo "expected 3 'not executable' lines (apply, listen, run), got $n" >&2 + exit 1 + fi + if echo "$out" \ + | grep -v "Command /usr/local/bin/pullgate is not executable" \ + | grep -v -E "^(/usr/lib/systemd/|/etc/systemd/)" \ + | grep -q .; then exit 1 fi