Skip to content

Commit c715397

Browse files
authored
[8.17] (backport #8311) bk: use elastic/vault-secrets and test-collector plugins together (#8360)
1 parent af0309d commit c715397

File tree

3 files changed

+5
-19
lines changed

3 files changed

+5
-19
lines changed

.buildkite/bk.integration.pipeline.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -439,7 +439,11 @@ steps:
439439
soft_fail:
440440
- exit_status: "*"
441441
plugins:
442-
- test-collector#v1.10.1:
442+
- elastic/vault-secrets#v0.1.0:
443+
path: "kv/ci-shared/platform-ingest/buildkite_analytics_token"
444+
field: "token"
445+
env_var: "BUILDKITE_ANALYTICS_TOKEN"
446+
- test-collector#v1.11.0:
443447
files: "build/*.xml"
444448
format: "junit"
445449
branches: "main"

.buildkite/hooks/pre-command

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -58,18 +58,6 @@ if [[ "$BUILDKITE_STEP_KEY" == *"integration-tests"* ]]; then
5858
export API_KEY_TOKEN=$(vault kv get -field apiKey ${CI_ESS_PATH})
5959
echo ${API_KEY_TOKEN} > ./apiKey
6060
export TEST_INTEG_AUTH_ESS_APIKEY_FILE=$(realpath ./apiKey)
61-
62-
# BK analytics
63-
echo "--- Prepare BK test analytics token :vault:"
64-
BUILDKITE_ANALYTICS_TOKEN=$(vault kv get -field token kv/ci-shared/platform-ingest/buildkite_analytics_token)
65-
export BUILDKITE_ANALYTICS_TOKEN
66-
fi
67-
68-
if [[ "$BUILDKITE_STEP_KEY" == *"aggregate-reports"* ]]; then
69-
# BK analytics
70-
echo "--- Prepare BK test analytics token :vault:"
71-
BUILDKITE_ANALYTICS_TOKEN=$(vault kv get -field token kv/ci-shared/platform-ingest/buildkite_analytics_token)
72-
export BUILDKITE_ANALYTICS_TOKEN
7361
fi
7462

7563
if [[ "$BUILDKITE_PIPELINE_SLUG" == "elastic-agent-binary-dra" ]]; then

.buildkite/scripts/steps/integration_tests_tf.sh

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -52,12 +52,6 @@ else
5252
export KIBANA_PASSWORD=$(buildkite-agent meta-data get "kibana.pwd")
5353
fi
5454

55-
# TODO: move to common.sh when it's refactored
56-
# BK analytics
57-
echo "--- Prepare BK test analytics token :vault:"
58-
BUILDKITE_ANALYTICS_TOKEN=$(vault kv get -field token kv/ci-shared/platform-ingest/buildkite_analytics_token)
59-
export BUILDKITE_ANALYTICS_TOKEN
60-
6155
# Run integration tests
6256
echo "~~~ Running integration tests"
6357

0 commit comments

Comments
 (0)