You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by da...@apache.org on 2024/07/31 07:42:06 UTC
(doris) 03/03: [chore](bash) support read env variables from doris_cloud.conf (#38060)
This is an automated email from the ASF dual-hosted git repository.
dataroaring pushed a commit to branch branch-3.0
in repository https://gitbox.apache.org/repos/asf/doris.git
commit 397cc68da3231eda1baa1bbc07eebdec7a85e5fc
Author: yagagagaga <zh...@gmail.com>
AuthorDate: Tue Jul 23 20:20:31 2024 +0800
[chore](bash) support read env variables from doris_cloud.conf (#38060)
---
cloud/script/start.sh | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/cloud/script/start.sh b/cloud/script/start.sh
index e119e193d82..94638957a86 100644
--- a/cloud/script/start.sh
+++ b/cloud/script/start.sh
@@ -40,6 +40,20 @@ for arg; do
done
# echo "$@" "daemonized=${daemonized}"}
+# export env variables from doris_cloud.conf
+# read from doris_cloud.conf
+while read -r line; do
+ envline="$(echo "${line}" |
+ sed 's/[[:blank:]]*=[[:blank:]]*/=/g' |
+ sed 's/^[[:blank:]]*//g' |
+ grep -E "^[[:upper:]]([[:upper:]]|_|[[:digit:]])*=" ||
+ true)"
+ envline="$(eval "echo ${envline}")"
+ if [[ "${envline}" == *"="* ]]; then
+ eval 'export "${envline}"'
+ fi
+done <"${DORIS_HOME}/conf/doris_cloud.conf"
+
process=doris_cloud
if [[ -f "${DORIS_HOME}/bin/${process}.pid" ]]; then
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org