From 481d70ce72560ae62ebe776826037685b868766e Mon Sep 17 00:00:00 2001 From: Vibe Myass Date: Mon, 16 Mar 2026 04:27:28 +0000 Subject: [PATCH] Improve smoke runner prerequisite diagnostics --- .gitea/workflows/smoke.yml | 26 +++++++++++++++++++++----- 1 file changed, 21 insertions(+), 5 deletions(-) diff --git a/.gitea/workflows/smoke.yml b/.gitea/workflows/smoke.yml index 5c62b9b..1520de3 100644 --- a/.gitea/workflows/smoke.yml +++ b/.gitea/workflows/smoke.yml @@ -15,11 +15,27 @@ jobs: - name: Verify runner prerequisites run: | set -euo pipefail - command -v bash >/dev/null - command -v curl >/dev/null - command -v gcc >/dev/null - command -v pkg-config >/dev/null - pkg-config --exists libnftables + require_cmd() { + if ! command -v "$1" >/dev/null 2>&1; then + echo "Missing required command: $1" >&2 + exit 1 + fi + } + + require_cmd bash + require_cmd curl + require_cmd gcc + require_cmd pkg-config + + if ! pkg-config --exists libnftables; then + echo "Missing libnftables pkg-config metadata on the runner host." >&2 + echo "Install the system libnftables development package before running this workflow." >&2 + exit 1 + fi + + echo "Runner prerequisites look good." + gcc --version | head -n 1 + pkg-config --modversion libnftables - name: Install .NET SDK run: |