Commit a96d5d1a authored by 智勇's avatar 智勇

每周更新

parent 12dd0d18
......@@ -10,7 +10,7 @@
source ~/.bash_profile
source ~/.profile
if [ $# -ne 8 ] -o [ $# -ne 9 ]; then
if [ $# -ne 9 ]; then
echo "---------------"
echo "source_db_infos:source_db_host: $1, source_db_user: $2"
echo "target_db_infos:target_db_host: $4, target_db_user: $5"
......
......@@ -21,31 +21,38 @@ function getCode()
cd $project_path
project_folder=`find ./ -maxdepth 1 -name "$project"`
if [ -n "$project_folder" ];then
echo "sh $config_server/show_info.sh $project pull代码 $desc $2"
sh $config_server/show_info.sh $project pull代码 $desc $2
echo "sh $config_server/show_info.sh $project pull代码 $desc $3"
sh $config_server/show_info.sh $project pull代码 $desc $3
cd ./$project
echo "git reset --hard"
git reset --hard
echo "git checkout ./"
git checkout ./
echo "git fetch"
git fetch
echo "git pull"
git pull
#如果拉代码失败,则获取现在所处分支,然后删掉现在的项目,重新clone
if [ $? -ne 0 ]; then
echo "error: Pulling is not possible because you have unmerged files"
git_branch=`git branch | grep '*' | awk '{print $2}'`
git_branch=`git branch | grep '*' | awk '{print $3}'`
echo $git_branch
cd $project_path
rm -rf $project_folder
sh $config_server/show_info.sh $project clone代码 $desc $2
sh $config_server/show_info.sh $project clone代码 $desc $3
git_path=`node $config_server/get_project_config.js -name $project -attr git_path`
git clone $git_path
cd ./$project
fi
if [ -n "$git_branch" -a $git_branch != "originalBBB" ]; then
if [ -n "$git_branch" ] && $git_branch != "originalBBB"; then
echo "git checkout -f $git_branch"
git checkout -f $git_branch
git_branch=$2
fi
git pull
git branch
else
sh $config_server/show_info.sh $project clone代码 $desc $2
sh $config_server/show_info.sh $project clone代码 $desc $3
git_path=`node $config_server/get_project_config.js -name $project -attr git_path`
git clone $git_path
fi
......@@ -65,8 +72,8 @@ elif [ "$project_type" = "python" ]
then
getCode python
else
getCode java $ip
getCode python $ip
getCode node $ip
getCode ui $ip
getCode java $2 $3
getCode python $2 $3
getCode node $2 $3
getCode ui $2 $3
fi
......@@ -54,8 +54,8 @@ tranceConfig java "xyqb.model.url=http:\/\/192.168.4.202\/Model\/openapi" "xyqb.
#4.14
#tranceConfig java 'cardniu.client.url=http://kn.feidee.net/loanmanage/loan/partner/k_n_user_quota_client.do' 'cardniu.client.url=http://192.168.4.248/mockjs/31/loanmanage/loan/partner/k_n_user_quota_client.do' "192.168.4.14" "xyqb.properties"
#tranceConfig java "cardniu.url=http://kn.feidee.net/loanmanage/loan/partner/k_n_user_quota.do" "cardniu.url=http://192.168.4.248/mockjs/31/loanmanage/loan/partner/k_n_user_quota.do" "192.168.4.14" "xyqb.properties"
tranceConfig java "xyqb.is.debug=0" "xyqb.is.debug=1" "192.168.4.14" "xyqb.properties"
tranceConfig nginx "\/home\/quant_group\/paycenter-ui\/dist" "\/home\/quant_group\/new-paycenter-ui\/dist" "192.168.4.14" "paycenter-ui.conf"
#tranceConfig java "xyqb.is.debug=0" "xyqb.is.debug=1" "192.168.4.14" "xyqb.properties"
#tranceConfig nginx "\/home\/quant_group\/paycenter-ui\/dist" "\/home\/quant_group\/new-paycenter-ui\/dist" "192.168.4.14" "paycenter-ui.conf"
#tranceConfig java "192.168.4.14:3306" "192.168.4.20:3306" "192.168.4.14" "*"
#tranceConfig java "192.168.4.14:7007" "139.198.2.95:1407" "192.168.4.14" "gu-bei.properties"
#tranceConfig python "192.168.4.14" "192.168.4.20" "192.168.4.14" "qin-qiong.*"
......@@ -74,6 +74,7 @@ tranceConfig nginx "\/home\/quant_group\/paycenter-ui\/dist" "\/home\/quant_grou
#tranceConfig java "139.198.2.95:1507" "wechattest1.xyqb.com" "192.168.4.15" "gu-bei.properties"
#tranceConfig java "loanorder" "loanstatus" "192.168.4.15" "xyqb.properties"
#tranceConfig java "xyqb-ui.url=http://192.168.4.15:7001" "xyqb-ui.url=http://192.168.4.15:7057" "192.168.4.15" "xyqb.properties"
tranceConfig java "mall-ui.url=http://192.168.4.15:7058" "mall-ui.url=http://wechattest1.xyqb.com" "192.168.4.15" "xyqb.properties"
#4.16
......@@ -86,12 +87,18 @@ tranceConfig nginx "\/home\/quant_group\/paycenter-ui\/dist" "\/home\/quant_grou
#tranceConfig node "112233445512345.ittun.com" "activity-op-22.ss.xyqb.loan" "192.168.4.22" "activity-op.js"
#tranceConfig java "xyqb.is.debug=1" "xyqb.is.debug=0" "192.168.4.22" "baitiao.properties"
#tranceConfig java "7002" "7050" "192.168.4.22" "baitiao.properties"
tranceConfig java "xyqb.is.debug=1" "xyqb.is.debug=0" "192.168.4.22" "xyqb.properties"
#tranceConfig node "7002" "7050" "192.168.4.22" "AppBackend.js"
#4.23
#tranceConfig node "db: {\n host: '192.168.4.23'" "db: {\n host: '192.168.4.8'" "192.168.4.23" "*"
#tranceConfig java "192.168.4.23:3306" "192.168.4.8:3306" "192.168.4.23" "*"
#tranceConfig node "dbIp: '192.168.4.23'" "dbIp: '192.168.4.8'" "192.168.4.23" "*"
#tranceConfig python "ip=192.168.4.23" "ip=192.168.4.8" "192.168.4.23" "qin-qiong*"
#tranceConfig java "192.168.4.23:3306" "192.168.4.8:3306" "192.168.4.23" "redpacket.properties"
#tranceConfig java "qatest" "Uiwb@o^fR&nHOa5t" "192.168.4.23" "redpacket.properties"
#tranceConfig java "redpacket.data.mysql.user=qa" "redpacket.data.mysql.user=xyqb_query" "192.168.4.23" "redpacket.properties"
tranceConfig node "192.168.4.50:9050" "192.168.4.23:7060" "192.168.4.23" "op-api.js"
#4.24
#tranceConfig java "sms.is.debug=1" "sms.is.debug=0" "192.168.4.24" "di-ting.properties"
......@@ -121,12 +128,8 @@ tranceConfig ui "wx89894cd83d117b26" "wx5b2e77c58fdcf1a5" "192.168.4.22" "xyqb-u
tranceConfig ui "11fb7f6a8b8edf2776a72c2f5624229c" "feb3c0705c1200f3759052310bde3369" "192.168.4.22" "xyqb-user-ui.js"
#end
tranceConfig java "wx89894cd83d117b26" "wxdf0392b9a648b646" "192.168.4.13" "xyqb-user2.properties"
tranceConfig java "11fb7f6a8b8edf2776a72c2f5624229c" "0849d140bbb50de8fceae2c4694e2e3f" "192.168.4.13" "xyqb-user2.properties"
tranceConfig ui "wx89894cd83d117b26" "wxdf0392b9a648b646" "192.168.4.13" "xyqb-user-ui.js"
tranceConfig ui "11fb7f6a8b8edf2776a72c2f5624229c" "0849d140bbb50de8fceae2c4694e2e3f" "192.168.4.13" "xyqb-user-ui.js"
tranceConfig ui "wechattest.xyqb.com" "wechattest2.xyqb.com" "192.168.4.13" "xyqb-user-ui.js"
......@@ -59,6 +59,8 @@ add_exchange baitiao_qrcode qrcode fanout
add_exchange /pay_center paycenter_exchange direct
add_exchange backend backend_message_rewrite_exc direct
add_exchange backend backend_file_exc direct
add_exchange /funding async direct
#add queues
add_queues /black_hole contractQueue
add_queues /black_hole generate_success
......@@ -103,6 +105,8 @@ add_queues /pay_center result_single_service_fee_queue
add_queues backend backend_message_rewrite_queue
add_queues backend backend_file_queue
add_queues /loan_order ka_loan_progress_queue
add_queues /funding generate_contract
#add bindings
add_binding backend backend_message_rewrite_exc backend_message_rewrite_queue backend_message_rewrite_route
......
#!/bin/bash
IP_host_first="192.168.4."
public_ip="139.198.2.95"
public_ip="www.q-gp.com" #"139.198.2.95"
pwd_path="/home/qa-deploy-utils/qa_shell_script"
config_server="$pwd_path/config_server"
ips=`cat $config_server/get_env_ip.sh`
......
#!/bin/bash
ip_last=$1
project_name=$2
branch_name=$3
project_type=$4
public_ip=$5
set timeout 1200
ip=192.168.4.$ip_last
echo "参数为:
#init_shell_script: ${init_shell_script}
ip : ${ip}
project_name : ${project_name}
branch_name : ${branch_name}
project_type : ${project_type}
public_ip : ${public_ip}
"
if [ -n "$project_name" ] && [ -n "$branch_name" ]; then
sshpass -p '!QAZ2wsx' ssh root@${ip}
cd /home/qa-deploy-utils/qa_shell_script
sh /home/qa-deploy-utils/qa_shell_script/deploy_project_by_name.sh $project_name $branch_name $public_ip
else
sshpass -p '!QAZ2wsx' ssh root@${ip}
cd /home/qa-deploy-utils/qa_shell_script
sh /home/qa-deploy-utils/qa_shell_script/deploy_project_by_type.sh $project_type $branch_name $public_ip
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