diff --git a/scripts/deploy.sh b/scripts/deploy.sh index 15a41945..eea808f5 100644 --- a/scripts/deploy.sh +++ b/scripts/deploy.sh @@ -11,27 +11,27 @@ mv ${WORKSPACE}/bonus-modules/bonus-material/target/bonus-material.jar $deploy_p chmod 777 *.jar echo "--------moveFile end--------------" -export bonus-material_enable=true -export bonus-material_jar=bonus-material.jar -export bonus-material_port=18588 +export bonus_material_enable=true +export bonus_material_jar=bonus-material.jar +export bonus_material_port=18588 -if($bonus-material_enable);then - echo "--------bonus-material 开始启动--------------" - echo "--------删除bonus-material开始--------------" - P_ID=`ps -ef | grep -w $bonus-material_jar | grep -v "grep" | awk '{print $2}'` +if($bonus_material_enable);then + echo "--------bonus_material 开始启动--------------" + echo "--------删除bonus__material开始--------------" + P_ID=`ps -ef | grep -w $bonus_material_jar | grep -v "grep" | awk '{print $2}'` if [ "$P_ID" == "" ]; then - echo "===bonus-material process not exists or stop success" + echo "===bonus_material process not exists or stop success" else kill -9 $P_ID - echo "bonus-material killed success" + echo "bonus_material killed success" fi - echo "--------bonus-material开始部署--------------" - nohup /usr/lib/jvm/jdk1.8.0_381/bin/java -jar $bonus-material_jar >/dev/null 2>&1 & - bonus-material_pid=`lsof -i:$bonus-material_port|grep "LISTEN"|awk '{print $2}'` - until [ -n "$bonus-material_pid" ] + echo "--------bonus_material开始部署--------------" + nohup /usr/lib/jvm/jdk1.8.0_381/bin/java -jar $bonus_material_jar >/dev/null 2>&1 & + bonus_material_pid=`lsof -i:$bonus_material_port|grep "LISTEN"|awk '{print $2}'` + until [ -n "$bonus_material_pid" ] do - bonus-material_pid=`lsof -i:$bonus-material_port|grep "LISTEN"|awk '{print $2}'` + bonus_material_pid=`lsof -i:$bonus_material_port|grep "LISTEN"|awk '{print $2}'` done - echo "bonus-material pid is $bonus-material_pid" - echo "--------bonus-material 启动成功--------------" + echo "bonus_material pid is $bonus_material_pid" + echo "--------bonus_material 启动成功--------------" fi \ No newline at end of file