From 8f3ebaf0a0d118759c9277842ab51d54faa7c5ec Mon Sep 17 00:00:00 2001 From: ianwremmel <1182361+ianwremmel@users.noreply.github.com> Date: Fri, 15 Apr 2022 21:26:17 -0700 Subject: [PATCH] fix: pass hostname from buildkite to cli --- .../check-run-reporter-buildkite-plugin/hooks/post-command | 2 ++ .../check-run-reporter-buildkite-plugin/hooks/pre-command | 2 ++ 2 files changed, 4 insertions(+) diff --git a/integrations/check-run-reporter-buildkite-plugin/hooks/post-command b/integrations/check-run-reporter-buildkite-plugin/hooks/post-command index fbd48af..254c1e1 100755 --- a/integrations/check-run-reporter-buildkite-plugin/hooks/post-command +++ b/integrations/check-run-reporter-buildkite-plugin/hooks/post-command @@ -43,6 +43,7 @@ log () { echo "$@" 1>&2 } +HOSTNAME=${BUILDKITE_PLUGIN_CHECK_RUN_REPORTER_HOSTNAME:-api.check-run-reporter.com} LABEL=${BUILDKITE_PLUGIN_CHECK_RUN_REPORTER_LABEL:-$BUILDKITE_LABEL} ROOT=${BUILDKITE_PLUGIN_CHECK_RUN_REPORTER_ROOT:-$(find_root)} SHA=$BUILDKITE_COMMIT @@ -65,6 +66,7 @@ else fi $BIN submit \ + --hostname="$HOSTNAME" \ --label="$LABEL" \ --report="$REPORT_DIR" \ --root="$ROOT" \ diff --git a/integrations/check-run-reporter-buildkite-plugin/hooks/pre-command b/integrations/check-run-reporter-buildkite-plugin/hooks/pre-command index 1aeb22f..47d3411 100755 --- a/integrations/check-run-reporter-buildkite-plugin/hooks/pre-command +++ b/integrations/check-run-reporter-buildkite-plugin/hooks/pre-command @@ -10,6 +10,7 @@ log () { echo "$@" 1>&2 } +HOSTNAME=${BUILDKITE_PLUGIN_CHECK_RUN_REPORTER_HOSTNAME:-api.check-run-reporter.com} LABEL=${BUILDKITE_PLUGIN_CHECK_RUN_REPORTER_LABEL:-$BUILDKITE_LABEL} TOKEN=$BUILDKITE_PLUGIN_CHECK_RUN_REPORTER_TOKEN TESTS=${BUILDKITE_PLUGIN_CHECK_RUN_REPORTER_TESTS:-''} @@ -39,6 +40,7 @@ fi export CHECK_RUN_REPORTER_TESTS_FOR_THIS_AGENT CHECK_RUN_REPORTER_TESTS_FOR_THIS_AGENT=$($BIN split \ + --hostname="$HOSTNAME" \ --label="$LABEL" \ --nodeCount="$NODE_COUNT" \ --nodeIndex="$NODE_INDEX" \