Skip to content

Commit 645670f

Browse files
authored
Merge pull request #4829 from xueyunyun/yunxue/fix_update_postscript
fix(brick_next): 低发行版升级到 7.12,默认没有初始化 brick_next 的 clientId 和 secret;后续手动打开开关后,升级 NA/NB 组件时获取 token 失败
2 parents b8f9f73 + 24a198b commit 645670f

File tree

2 files changed

+10
-18
lines changed

2 files changed

+10
-18
lines changed

packages/brick-container/deploy/install_postscript.sh

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,11 @@ config_tool="${deploy_init_path}/tools/config_tool"
1212

1313
export LD_LIBRARY_PATH=/usr/local/easyops/ens_client/sdk:${LD_LIBRARY_PATH}
1414

15-
16-
value=$(${config_tool} get --appID "deploy_init" --namespaceName "common" --key "check_auth_token.enable")
17-
if [[ ${value} == "true" ]]; then
18-
# 初始化默认命名空间,并生成 clientId 和 secret
19-
${config_tool} init -f "${install_path}/conf/config.yaml"
20-
if [[ $? -ne 0 ]];then
21-
echo "import brick_next_v3 config namespace error, exit"
22-
exit 1
23-
fi
15+
# 初始化默认命名空间,并生成 clientId 和 secret
16+
${config_tool} init -f "${install_path}/conf/config.yaml"
17+
if [[ $? -ne 0 ]];then
18+
echo "import brick_next config namespace error, exit"
19+
exit 1
2420
fi
2521

2622

packages/brick-container/deploy/update_postscript.sh

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -57,15 +57,11 @@ if [[ ${org}X == X ]]; then
5757
[[ $? -ne 0 ]] && echo "get org error, exit" && exit 1
5858
fi
5959

60-
61-
value=$(${config_tool} get --appID "deploy_init" --namespaceName "common" --key "check_auth_token.enable")
62-
if [[ ${value} == "true" ]]; then
63-
# 初始化默认命名空间,并生成 clientId 和 secret
64-
${config_tool} init -f "${install_path}/conf/config.yaml"
65-
if [[ $? -ne 0 ]];then
66-
echo "import brick_next_v3 config namespace error, exit"
67-
exit 1
68-
fi
60+
# 初始化默认命名空间,并生成 clientId 和 secret
61+
${config_tool} init -f "${install_path}/conf/config.yaml"
62+
if [[ $? -ne 0 ]];then
63+
echo "import brick_next config namespace error, exit"
64+
exit 1
6965
fi
7066

7167

0 commit comments

Comments
 (0)