标签:
#!/bin/bash
#设置变量
cd /home
#停止tomcat
echo "开始停止tomcat..."
ps x | grep java | grep -v grep | awk ‘{print $1}‘ | xargs kill -9
#ps x | grep java | grep -v grep | awk ‘{print $1}‘
#ps x | grep java | grep -v grep | kill -9 $1
#echo $1
#kill -9 $1
ps x | grep java | grep -v grep | awk ‘{print $1}‘
sleep 1
echo "tomcat已停止"
echo "========================================================================="
echo "checkout 源代码..."
svn co svn://172.16.16.220/MDMP/trunk/mdmp-all mdmp --username jirauser --password jirauser --no-auth-cache --non-interactive
echo "完成checkout 源代码"
echo "========================================================================="
cd mdmp
echo "开始clean mdmp项目..."
mvn clean
echo "完成clean mdmp项目"
echo "========================================================================="
echo "开始部署个性配置..."
echo "完成个性配置"
echo "开始install mdmp项目..."
mvn install -Dmaven.test.skip=true
echo "完成install fdap项目"
cp -r /home/conf/config.properties mdmp-web/src/main/resources/config.properties
cp -r deploy.sh /home/deploy.sh
cd mdmp-web
echo "开始启动tomcat"
mvn tomcat:run
标签:
原文地址:http://www.cnblogs.com/hutuchong/p/4819193.html