Skip to content

Commit

Permalink
Fix BUILDKITE_ANALYTICS_TOKEN (#6163)
Browse files Browse the repository at this point in the history
  • Loading branch information
pazone authored Nov 28, 2024
1 parent fe0f6b0 commit be97be9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
5 changes: 5 additions & 0 deletions .buildkite/hooks/pre-command
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,11 @@ if [[ "$BUILDKITE_STEP_KEY" == *"integration-tests"* ]]; then
export API_KEY_TOKEN=$(vault kv get -field apiKey ${CI_ESS_PATH})
echo ${API_KEY_TOKEN} > ./apiKey
export TEST_INTEG_AUTH_ESS_APIKEY_FILE=$(realpath ./apiKey)

# BK analytics
echo "--- Prepare BK test analytics token :vault:"
BUILDKITE_ANALYTICS_TOKEN=$(vault kv get -field token kv/ci-shared/platform-ingest/buildkite_analytics_token)
export BUILDKITE_ANALYTICS_TOKEN
fi

if [[ "$BUILDKITE_PIPELINE_SLUG" == "elastic-agent-binary-dra" ]]; then
Expand Down
6 changes: 0 additions & 6 deletions .buildkite/scripts/steps/integration_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,6 @@ if [[ -n "$STACK_VERSION" ]]; then
STACK_VERSION=${STACK_VERSION}"-SNAPSHOT"
fi

# TODO: move to common.sh when it's refactored
# BK analytics
echo "--- Prepare BK test analytics token :vault:"
BUILDKITE_ANALYTICS_TOKEN=$(vault kv get -field token kv/ci-shared/platform-ingest/buildkite_analytics_token)
export BUILDKITE_ANALYTICS_TOKEN

# Run integration tests
set +e
AGENT_STACK_VERSION="${STACK_VERSION}" TEST_INTEG_CLEAN_ON_EXIT=true STACK_PROVISIONER="$STACK_PROVISIONER" SNAPSHOT=true mage $MAGE_TARGET $MAGE_SUBTARGET
Expand Down

0 comments on commit be97be9

Please sign in to comment.