forked from elastic/elastic-charts
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpre-command
More file actions
executable file
·40 lines (23 loc) · 965 Bytes
/
pre-command
File metadata and controls
executable file
·40 lines (23 loc) · 965 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#!/usr/bin/env bash
set -euo pipefail
source .buildkite/scripts/utils.sh
echo '--- Setting job environment variables'
# kibanamachine token to access org
GITHUB_TOKEN=$(retry 5 5 vault read -field=github_token secret/ci/elastic-elastic-charts/kibanamachine)
export GITHUB_TOKEN
# charts github app to send checks
GITHUB_AUTH=$(retry 5 5 vault read -field=auth secret/ci/elastic-elastic-charts/github | base64 -d)
export GITHUB_AUTH
FIREBASE_AUTH=$(retry 5 5 vault read -field=auth secret/ci/elastic-elastic-charts/firebase | base64 -d)
export FIREBASE_AUTH
BUILDKITE_TOKEN=$(retry 5 5 vault read -field=token secret/ci/elastic-elastic-charts/buildkite)
export BUILDKITE_TOKEN
source .buildkite/scripts/node_setup.sh
cd '.buildkite'
echo '--- Installing buildkite dependencies'
retry 5 15 install_deps
echo '--- Generating buildkite files'
yarn build:bk:types
echo '--- Updating commit status for jobs'
# npx ts-node scripts/pre_command.ts
cd '../'