forked from tikv/pd
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This is an automated cherry-pick of tikv#8270
ref tikv#7298 Signed-off-by: ti-chi-bot <ti-community-prow-bot@tidb.io>
- Loading branch information
1 parent
7f4c846
commit 958c5bb
Showing
1 changed file
with
32 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
#!/bin/bash | ||
# deploy `tiup playground` | ||
|
||
TIUP_BIN_DIR=$HOME/.tiup/bin/tiup | ||
CUR_PATH=$(pwd) | ||
|
||
# See https://misc.flogisoft.com/bash/tip_colors_and_formatting. | ||
color-green() { # Green | ||
echo -e "\x1B[1;32m${*}\x1B[0m" | ||
} | ||
|
||
# Install TiUP | ||
color-green "install TiUP..." | ||
curl --proto '=https' --tlsv1.2 -sSf https://tiup-mirrors.pingcap.com/install.sh | sh | ||
$TIUP_BIN_DIR update playground | ||
|
||
cd ../../.. | ||
if [ ! -d "bin" ] || [ ! -e "bin/tikv-server" ] && [ ! -e "bin/tidb-server" ] && [ ! -e "bin/tiflash" ]; then | ||
color-green "downloading binaries..." | ||
color-green "this may take a few minutes, you can also download them manually and put them in the bin directory." | ||
make pd-server WITH_RACE=1 | ||
$TIUP_BIN_DIR playground nightly --kv 3 --tiflash 1 --db 1 --pd 3 --without-monitor --tag pd_test \ | ||
--pd.binpath ./bin/pd-server \ | ||
> $CUR_PATH/playground.log 2>&1 & | ||
else | ||
color-green "using existing binaries..." | ||
$TIUP_BIN_DIR playground nightly --kv 3 --tiflash 1 --db 1 --pd 3 --without-monitor \ | ||
--pd.binpath ./bin/pd-server --kv.binpath ./bin/tikv-server --db.binpath ./bin/tidb-server --tiflash.binpath ./bin/tiflash --tag pd_test \ | ||
> $CUR_PATH/playground.log 2>&1 & | ||
fi | ||
|
||
cd $CUR_PATH |