From 81258cf83ffcc40ec56953d6c70990e17580d9b7 Mon Sep 17 00:00:00 2001 From: Lars Erik Wik Date: Wed, 23 Sep 2026 12:59:53 +0200 Subject: [PATCH] Fixed build host setup failing when journal has no errors cleanup() runs under set -e, so the journalctl grep failed the build when it found no matching lines. Co-Authored-By: Claude Opus 5.5 (1M context) Signed-off-by: Lars Erik Wik --- ci/setup-cfengine-build-host.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/setup-cfengine-build-host.sh b/ci/setup-cfengine-build-host.sh index 3a4523c6f..087cae49c 100755 --- a/ci/setup-cfengine-build-host.sh +++ b/ci/setup-cfengine-build-host.sh @@ -62,7 +62,7 @@ function cleanup() { set -e set -x [ -f /var/log/messages ] && tail /var/log/messages - command -v journalctl >/dev/null && journalctl | grep -P '(error|fail)' + command -v journalctl >/dev/null && journalctl | grep -P '(error|fail)' || true if command -v apt >/dev/null 2>&1; then # workaround for CFE-4544, remove scriptlets call systemctl even when systemctl is-system-running returns false # Replace systemctl with a no-op stub that always succeeds. We can't