From 273d6162de43c87166b4a8d54f1dccc85e478961 Mon Sep 17 00:00:00 2001 From: Christoph Meyer Date: Wed, 2 Nov 2022 15:34:30 +0000 Subject: [PATCH] fix: don't run CI K-Bench with less than 2 worker nodes K-Bench's network benchmarks require two distinct worker nodes. Add check prior to running the benchmark that terminates early, if not enough workers scheduled. --- .github/actions/e2e_test/action.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.github/actions/e2e_test/action.yml b/.github/actions/e2e_test/action.yml index 465d0dbbf..422fd9e4f 100644 --- a/.github/actions/e2e_test/action.yml +++ b/.github/actions/e2e_test/action.yml @@ -56,6 +56,16 @@ runs: echo "Invalid input for test field: ${{ inputs.test }}" exit 1 + # K-Bench's network benchmarks require at least two distinct worker nodes. + - name: Validate k-bench inputs + if: inputs.test == 'k-bench' + shell: bash + run: | + if [[ "${{ inputs.workerNodesCount }}" -lt 2 ]]; then + echo "::error::Test K-Bench requires at least 2 worker nodes." + exit 1 + fi + - name: Determine build target id: determine-build-target shell: bash