Commit 44f74a48 authored by vipwzw's avatar vipwzw

auto ci

parent 37f52000
...@@ -102,7 +102,7 @@ function StartRelayerAndDeploy() { ...@@ -102,7 +102,7 @@ function StartRelayerAndDeploy() {
# 修改 relayer.toml 配置文件 # 修改 relayer.toml 配置文件
updata_relayer_toml "${BridgeRegistry}" ${maturityDegree} "./relayer.toml" updata_relayer_toml "${BridgeRegistry}" ${maturityDegree} "./relayer.toml"
# 重启 # 重启
start_ebrelayerA start_ebrelayerA
# start ebrelayer B C D # start ebrelayer B C D
for name in b c d; do for name in b c d; do
......
...@@ -15,7 +15,7 @@ NOC='\033[0m' ...@@ -15,7 +15,7 @@ NOC='\033[0m'
# 出错退出前拷贝日志文件 # 出错退出前拷贝日志文件
function exit_cp_file() { function exit_cp_file() {
# shellcheck disable=SC2116 # shellcheck disable=SC2116
# dirNameFa=$(echo ~) # dirNameFa=$(echo ~)
dirName="/x2ethereumlogs" dirName="/x2ethereumlogs"
if [ ! -d "${dirName}" ]; then if [ ! -d "${dirName}" ]; then
...@@ -36,7 +36,7 @@ function copyErrLogs() { ...@@ -36,7 +36,7 @@ function copyErrLogs() {
if [ -n "$CASE_ERR" ]; then if [ -n "$CASE_ERR" ]; then
# /var/lib/jenkins # /var/lib/jenkins
# shellcheck disable=SC2116 # shellcheck disable=SC2116
# dirNameFa=$(echo ~) # dirNameFa=$(echo ~)
dirName="/x2ethereumlogs" dirName="/x2ethereumlogs"
if [ ! -d "${dirName}" ]; then if [ ! -d "${dirName}" ]; then
...@@ -128,14 +128,14 @@ function start_docker_ebrelayer() { ...@@ -128,14 +128,14 @@ function start_docker_ebrelayer() {
fi fi
# 后台启动程序 # 后台启动程序
docker exec "$1" nohup "${2}" > "${3}" 2>&1 & docker exec "$1" nohup "${2}" >"${3}" 2>&1 &
sleep 2 sleep 2
# shellcheck disable=SC2009 # shellcheck disable=SC2009
pid=$(docker exec "$1" ps -ef | grep "$2" | grep -v 'grep' | awk '{print $2}') pid=$(docker exec "$1" ps -ef | grep "$2" | grep -v 'grep' | awk '{print $2}')
local count=0 local count=0
while [ "${pid}" == "" ]; do while [ "${pid}" == "" ]; do
docker exec "$1" nohup "${2}" > "${3}" 2>&1 & docker exec "$1" nohup "${2}" >"${3}" 2>&1 &
sleep 2 sleep 2
count=$((count + 1)) count=$((count + 1))
......
...@@ -6,4 +6,4 @@ set +e ...@@ -6,4 +6,4 @@ set +e
while [ 1 == 1 ]; do while [ 1 == 1 ]; do
sleep 100 sleep 100
done done
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment