您的位置:首页 > 运维架构 > Shell

shell脚本重启编译应用

2016-07-26 11:37 405 查看
#!/bin/sh
#kill tomcat pid
pidlist=`ps -ef|grep tomcat|grep -v "grep"|awk '{print $2}'`
if [ "$pidlist" = "" ]
then
echo "no tomcat pid alive!"
else
echo "tomcat Id list :$pidlist"
kill -9 $pidlist
echo "KILL $pidlist:"
echo "service stop success"
fi
echo "ant build"
ant clean;
ant build;
echo "start tomcat"
cd /work/tomcat/apache-tomcat-8.0.35/bin/
./startup.sh ;
echo "gulp ing"
cd /home/project/webapp
gulp build:zb
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: