Commit 58146316 authored by qa_quantgroup's avatar qa_quantgroup

增加jenkins构建后脚本

parent 3e933b83
...@@ -11,6 +11,12 @@ else ...@@ -11,6 +11,12 @@ else
exit -1 exit -1
fi fi
sh /home/qa-deploy-utils/qa_shell_script/3_link_config_file_by_name.sh $project_name $public_ip $4 sh /home/qa-deploy-utils/qa_shell_script/3_link_config_file_by_name.sh $project_name $public_ip $4
if [ $? = 0 ]; then
echo "3_link_config_file_by_name.sh ok"
else
echo "3_link_config_file_by_name.sh fail"
exit -1
fi
sh /home/qa-deploy-utils/qa_shell_script/4_build_by_name.sh $project_name $public_ip $4 sh /home/qa-deploy-utils/qa_shell_script/4_build_by_name.sh $project_name $public_ip $4
if [ $? = 0 ]; then if [ $? = 0 ]; then
echo "4_build_by_name ok" echo "4_build_by_name ok"
......
#!/bin/bash
cd $JENKINS_HOME/jobs/$JOB_BASE_NAME/builds/${BUILD_NUMBER}
res=`grep "2_get_code_by_name fail" log`
if [ -n "$res" ];then
echo "2_get_code_by_name fail"
exit -1
fi
res=`grep "3_link_config_file_by_name.sh fail" log`
if [ -n "$res" ];then
echo "3_link_config_file_by_name.sh fail"
exit -1
fi
res=`grep "4_build_by_name fail" log`
if [ -n "$res" ];then
echo "4_build_by_name fail"
exit -1
fi
res=`grep "5_restart_by_name fail" log`
if [ -n "$res" ];then
echo "5_restart_by_name fail"
exit -1
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