Commit 748dcda9 authored by 白秀江's avatar 白秀江

更新project-deploy.sh

parent f1ae422c
...@@ -45,13 +45,18 @@ function restart() { ...@@ -45,13 +45,18 @@ function restart() {
# #
# $1 方法名 检查项目运行状态 # $1 方法名 检查项目运行状态
# $2 项目目录 # $2 url
# $3 keyword
# #
function check() { function check() {
keyword = $3
if [ $keyword -z ]; then
keyword = "success"
fi
while [ $COUNT -lt 1 ]; do while [ $COUNT -lt 1 ]; do
echo -e ".\c" echo -e ".\c"
sleep 1 sleep 1
COUNT=`curl -v "$3" | grep "success" | wc -l` COUNT=`curl -v "$2" | grep $keyword | wc -l`
if [ $COUNT -gt 0 ]; then if [ $COUNT -gt 0 ]; then
break break
fi fi
......
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