Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 22 additions & 14 deletions docker/runtime/be/resource/entry_point.sh
Original file line number Diff line number Diff line change
Expand Up @@ -261,21 +261,29 @@ check_arg() {

_main() {
docker_required_variables_env
# get init args
get_doris_args
docker_setup_env
# Start Doris BE
{
set +e
bash init_be.sh 2>/dev/null
} &
# check BE started status
check_be_status
if [ -z ${DATABASE_ALREADY_EXISTS} ]; then
# run script
sleep 15
docker_process_init_files /docker-entrypoint-initdb.d/*
trap 'cleanup' SIGTERM SIGINT
if [[ $RUN_TYPE == "K8S" ]]; then
start_be.sh &
child_pid=$!
else
# get init args
get_doris_args
docker_setup_env
# Start Doris BE
{
set +e
bash init_be.sh 2>/dev/null
} &
# check BE started status
check_be_status
if [ -z ${DATABASE_ALREADY_EXISTS} ]; then
# run script
sleep 15
docker_process_init_files /docker-entrypoint-initdb.d/*
fi
fi
wait $child_pid
exec "$@"

# keep BE started status
wait
Expand Down