master
pan 4 years ago
parent c20492b3df
commit 65c34e387f
  1. 17
      shell/updateRisk

@ -13,12 +13,21 @@ export apiServer=https://risk.kirito.cool
function run(){
if [ ! -e $1 ]
then
git clone git@gogs.kirito.cool:panqihua/$1.git
git clone git@gogs.kirito.cool:panqihua/$1.git
isUpdate=false
else
isUpdate=true
fi
cd $1 && git reset --hard && git pull && yarn && chmod +x run.sh && killNode
# url="http://127.0.0.1:3000/finsh?name=$1"
# echo "成功回调地址:$url"
# curl $url
if [ $isUpdate ]
then
echo "克隆仓库代码"
url="http://127.0.0.1:3000/finsh?name=$1"
echo "成功回调地址:$url"
curl $url
else
echo "更新仓库代码"
fi
}
#检查是否正在部署

Loading…
Cancel
Save