Commit d26dd5b7 authored by qa_quantgroup's avatar qa_quantgroup

fix

parent 62ba00dc
......@@ -40,13 +40,17 @@ then
else
if $is_public_ip && [ -n "$is_public_ip" ]
then
echo "ln -s $config_path/public/$project_type/${project}.* /home/quant_group/${project}/$file"
ln -s $config_path/public/$project_type/${project}.* /home/quant_group/${project}/$file
if [ $? != 0 ];then
echo "link config file fail"
exit -1
fi
else
ln -s $config_path/$project_type/${project}.* /home/quant_group/${project}/$file
echo "ln -s $config_path/$project_type/${project}.* /home/quant_group/${project}/$file"
ln -s "$config_path/$project_type/${project}.*" /home/quant_group/${project}/$file
if [ $? != 0 ];then
echo "link config file fail"
exit -1
fi
fi
......
......@@ -15,7 +15,7 @@ function restartJavaProject()
{
max_wait_log_generate_time=50
max_wait_ack_time=500
ack_phrase="Started\ Bootstrap"
ack_phrase="JVM\ running\ for"
project=$1
desc=`node $config_server/get_project_config.js -name $project -attr desc`
sh $config_server/show_info.sh $project 重新启动 $desc
......
......@@ -19,8 +19,8 @@ sh $config_server/show_info.sh $project BUILD $desc `hostname`
# 第一步 将nginx项目的所有文件进行打包
cd $project_path/$project
#第二步 关联配置文件
rm -rf ./$config_file
echo "------ln -s $config_path/node/$project.* ./$config_file"
ln -s $config_path/node/$project.* ./$config_file
#rm -rf ./$config_file
#echo "------ln -s $config_path/node/$project.* ./$config_file"
#ln -s $config_path/node/$project.* ./$config_file
npm config set "@types:registry" http://registry.npmjs.org/
npm --registry http://172.16.3.15:4873 install
......@@ -14,5 +14,5 @@ cd $project_path/$project
setup_path_temp=`find ./ -name "setup.py"`
python ${setup_path_temp} install
#第四步 关联配置文件
rm -rf $config_file
ln -s $config_path/python/$project.* $config_file
\ No newline at end of file
#rm -rf $config_file
#ln -s $config_path/python/$project.* $config_file
......@@ -49,7 +49,7 @@ function ack()
max_wait_log_generate_time=50
max_wait_ack_time=500
ack_phrase="Started\ Bootstrap"
ack_phrase="JVM\ running\ for"
project=$1
desc=`node $config_server/get_project_config.js -name $project -attr desc`
run_command_=`node $config_server/get_project_config.js -name $project -attr command`
......
12 13 14 15 16 17 22 23 24 25 26 28 46 50 59 60 72 151 152 153 154 155 156 158 160 161 162 163 164
12 13 14 15 16 17 22 23 24 25 26 28 46 50 59 60 72 74 75 76 151 152 153 154 155 156 158 160 161 162 163 164
......@@ -114,7 +114,7 @@ new pClass().init(true, "ui", "7004", "r.xyqb.com", "di-ting-ui", false, "QG", n
new pClass().init(true, "ui", "7020", "", "spider-center-ui", false, "QG", null, "src/app/config/env.config.js", "npm run qa", "node7", 1, "授信中心-ui", "", "", "");
new pClass().init(true, "ui", "7050", "bt.xyqb.com", "bt-ui", false, "QG", null, "src/app/config/env.config.js", "npm --registry http://172.16.3.15:4873 run qa", "node7", 1, "新版白条-ui", "", "", "");
new pClass().init(true, "ui", "7058", "", "mall-ui", true, "ui", null, "src/app/config/env.config.js", "npm run build", "node7", 1, "商城-ui", "", "", "");
new pClass().init(true, "ui", "7001", "m.xyqb.com", "xyqb-ui", false, "QG", null, "client/app/config.js", "grunt build", "node4", 1, "现金贷和白条-现金贷-ui", "", "", "");
new pClass().init(true, "ui", "7001", "m.xyqb.com", "xyqb-ui", false, "QG", null, "client/app/config.js", "grunt build", "node7", 1, "现金贷和白条-现金贷-ui", "", "", "");
new pClass().init(true, "ui", "7046", "", "activity-op-ui", false, "QG", null, "src/config/env.config.js", "npm run build", "node7", 1, "优惠券管理后台-ui", "", "", "");
new pClass().init(true, "ui", "7048", "", "order-op-ui", false, "OP", null, "src/js/env.config.js", "gulp build", "node7", 1, "订单系统-ui", "", "", "");
new pClass().init(true, "ui", "7002", "", "qgbc-ui", false, "QG", null, "src/app/config/env.config.js", "npm run build_production", "node7", 1, "白条-ui", "", "", "");
......
......@@ -37,7 +37,6 @@ function tranceConfig()
}
#4.12
#tranceConfig node "192.168.4.3" "192.168.4.107" "192.168.4.12" "AppBackend.js"
#tranceConfig ui "7047" "12047" "192.168.4.12" "merchant-op-ui.js"
#tranceConfig java "spider-center.host=http:\/\/192.168.4.12:7021\/" "spider-center.host=http:\/\/spider-center-12.ss.xyqb.loan\/" "192.168.4.12" "spider-center.properties"
#tranceConfig ui "7041" "7054" "192.168.4.12" "activity-ui.js"
......@@ -57,8 +56,8 @@ tranceConfig ui "wechattest.xyqb.com" "wechattest2.xyqb.com" "192.168.4.12" "xyq
#tranceConfig java "pay.debug=0" "pay.debug=1" "192.168.4.13" "xyqb-mall.properties"
tranceConfig java "red.packet.id=10000115" "red.packet.id=56" "192.168.4.13" "xyqb-mall.properties"
tranceConfig java "7002" "7050" "192.168.4.13" "baitiao.properties"
tranceConfig java "lkb.model.url=http:\/\/192.168.4.202\/Model\/openapi" "lkb.model.url=http:\/\/192.168.4.13:8090\/Model\/openapi" "192.168.4.13" "baitiao.properties"
tranceConfig java "xyqb.model.url=http:\/\/192.168.4.202\/Model\/openapi" "xyqb.model.url=http:\/\/192.168.4.13:8090\/Model\/openapi" "192.168.4.13" "baitiao.properties"
#tranceConfig java "lkb.model.url=http:\/\/192.168.4.202\/Model\/openapi" "lkb.model.url=http:\/\/192.168.4.13:8090\/Model\/openapi" "192.168.4.13" "baitiao.properties"
#tranceConfig java "xyqb.model.url=http:\/\/192.168.4.202\/Model\/openapi" "xyqb.model.url=http:\/\/192.168.4.13:8090\/Model\/openapi" "192.168.4.13" "baitiao.properties"
tranceConfig java "wx89894cd83d117b26" "wx5b2e77c58fdcf1a5" "192.168.4.13" "xyqb-user2.properties"
tranceConfig java "11fb7f6a8b8edf2776a72c2f5624229c" "feb3c0705c1200f3759052310bde3369" "192.168.4.13" "xyqb-user2.properties"
tranceConfig ui "wx89894cd83d117b26" "wx5b2e77c58fdcf1a5" "192.168.4.13" "xyqb-user-ui.js"
......@@ -168,7 +167,7 @@ tranceConfig java "139.198.2.95:2231" "192.168.4.22:7031" "192.168.4.22" "xyqb.p
#4.156
tranceConfig java "http:\/\/192.168.4.241\/" "http:\/\/221.207.229.3:17500\/wlpf\/HttpServer\/XFXD_INPUT_SVR\/" "192.168.4.156" "baitiao-zhitou.properties"
#tranceConfig java "http:\/\/192.168.4.156:7017\/eureka\/" "http:\/\/192.168.4.152:7017\/eureka\/" "192.168.4.156" "baitiao.properties"
tranceConfig java "eureka.client.serviceUrl.defaultZone=http://192.168.4.156:7017/eureka/" "eureka.client.serviceUrl.defaultZone=http://192.168.4.17:7017/eureka/" "192.168.4.156" "baitiao-zhitou.properties"
#tranceConfig java "eureka.client.serviceUrl.defaultZone=http://192.168.4.156:7017/eureka/" "eureka.client.serviceUrl.defaultZone=http://192.168.4.17:7017/eureka/" "192.168.4.156" "baitiao-zhitou.properties"
#微信环境修改,请勿删除,可以注释
tranceConfig java "wx89894cd83d117b26" "wx5b2e77c58fdcf1a5" "192.168.4.22" "xyqb-user2.properties"
tranceConfig java "11fb7f6a8b8edf2776a72c2f5624229c" "feb3c0705c1200f3759052310bde3369" "192.168.4.22" "xyqb-user2.properties"
......
#!/bin/bash
npm config set registry http://172.16.3.15:4873/
......@@ -26,7 +26,7 @@ function authorization()
term_no=`mysql -N $mysqld xyqb -e "select count(*) from baitiao_bill_repayment_plan where order_id='$order_id'"`
baitiao_fund_repayment_plan=`mysql -N $mysqld xyqb -e "select id from baitiao_fund_repayment_plan where plan_id='$plan_id'"`
if [[ -n "baitiao_fund_repayment_plan" ]]; then
if [[ -n "$baitiao_fund_repayment_plan" ]]; then
echo "finish~"
exit
else
......@@ -51,7 +51,7 @@ function authorization()
#echo $update_sql
mon=`date "+%Y%m"`
insert_sql0="insert into baitiao_bill("user_id","user_phone","month","already_repay_amount","bill_repay_status","enable") values ('$user_id','$phone_no','$mon','0','0','1')"
insert_sql0="insert into baitiao_bill("user_id","user_phone","month","already_repay_amount","bill_repay_status","enable") values ('$user_id','$phone_no','$mon','0','1','1')"
mysql $mysqld ${DBNAME} -e "${insert_sql0}"
#echo $insert_sql0
mon=`date -d '1 month' '+%Y%m'`
......@@ -63,18 +63,18 @@ function authorization()
mysql $mysqld ${DBNAME} -e "${insert_sql0}"
#echo $insert_sql0
bill_id=`mysql -N $mysqld xyqb -e "select id from baitiao_bill where user_id='$user_id' limit 1"`
bill_id=`mysql -N $mysqld xyqb -e "select id from baitiao_bill where user_id='$user_id' order by id desc limit 1"`
echo "bill_id=$bill_id"
#insert_sql0="insert into baitiao_finance_record("third_no","total_amount","local_no","type","remark") values ('$date',10000,NULL,'0',N'笑脸资金方批量放款到量化派')"
#mysql $mysqld ${DBNAME} -e "${insert_sql0}"
update_sql="update baitiao_bill_repayment_plan set bill_id=$bill_id where order_id=$order_id and term_no=1"
update_sql="update baitiao_bill_repayment_plan set bill_id=$bill_id-2 where order_id=$order_id and term_no=1"
mysql $mysqld ${DBNAME} -e "${update_sql}"
#echo $update_sql
update_sql="update baitiao_bill_repayment_plan set bill_id=$bill_id+1 where order_id=$order_id and term_no=2"
update_sql="update baitiao_bill_repayment_plan set bill_id=$bill_id-1 where order_id=$order_id and term_no=2"
mysql $mysqld ${DBNAME} -e "${update_sql}"
#echo $update_sql
update_sql="update baitiao_bill_repayment_plan set bill_id=$bill_id+2 where order_id=$order_id and term_no=3"
update_sql="update baitiao_bill_repayment_plan set bill_id=$bill_id where order_id=$order_id and term_no=3"
mysql $mysqld ${DBNAME} -e "${update_sql}"
#echo $update_sql
......
......@@ -31,7 +31,7 @@ values
where user_id=(select id from xyqb_user.user where phone_no='$phone_no')),0,'$seq');
update xyqb.baitiao_account
set pay_pwd='7da26eb97215a944743cc22d49e39f0d', pay_pwd_salt='NkUzMjY3QjIzQTEzMjdBNDQzM0M2MTIz'
set pay_pwd='dfd3514d3c2dadbeb3b0774a08f591cb', pay_pwd_salt='QUYzRkUyMDFBRkU1NzUzNjEzRURBMkM5'
where user_id=(
select id from xyqb_user.user where phone_no='$phone_no');
......
#!/bin/bash
IP_host_first="192.168.4."
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`
mkdir -p /home/sub_config_file_dont_rm
for ip_last_num in ${ips[@]}
do
echo "开始生成${IP_host_first}${ip_last_num}"
cd /home/sub_config_file_dont_rm
mkdir -p ${IP_host_first}${ip_last_num}
cd ${IP_host_first}${ip_last_num}
dir=`pwd`
#java项目发布
rm -rf $dir/java
mkdir $dir/java
rm -rf $dir/public
mkdir $dir/public
rm -rf $dir/public/java
mkdir $dir/public/java
rm -rf $dir/public/node
mkdir $dir/public/node
cp -rf /home/config_files/java/* $dir/java/
cp -rf /home/config_files/java/* $dir/public/java/
sed -i "s/target_host_name/${IP_host_first}${ip_last_num}/" $dir/java/*
sed -i "s/target_mq_host_name/${IP_host_first}${ip_last_num}/" $dir/java/*
sed -i "s/target_host_name:70/${public_ip}:${ip_last_num}/g" $dir/public/java/*
#gu-bei的回调接口都改成外网接口
#sed -i "s/callback=http:\/\/${IP_host_first}${ip_last_num}:7006/callback=http:\/\/${public_ip}:${ip_last_num}06/g" $dir/java/gu-bei.properties
#sed -i "s/pay_notify_url=http:\/\/${IP_host_first}${ip_last_num}:7006/pay_notify_url=http:\/\/${public_ip}:${ip_last_num}06/g" $dir/java/gu-bei.properties
# fi
sed -i "s/target_host_name/${public_ip}/g" $dir/public/java/*
sed -i "s/target_mq_host_name/${IP_host_first}${ip_last_num}/" $dir/public/java/*
sed -i "s/${public_ip}:3306/${IP_host_first}${ip_last_num}:3306/g" $dir/public/java/*
sed -i "s/redis.master.host=${public_ip}/redis.master.host=${IP_host_first}${ip_last_num}/g" $dir/public/java/*
sed -i "s/zk.connect.url=${public_ip}/zk.connect.url=${IP_host_first}${ip_last_num}/g" $dir/public/java/*
sed -i "s/registry.address=${public_ip}:2181/registry.address=${IP_host_first}${ip_last_num}:2181/g" $dir/public/java/*
sed -i "s/${public_ip}:${ip_last_num}62/${IP_host_first}${ip_last_num}:7062/g" $dir/public/java/*
sed -i "s/ip_last/$ip_last_num/g" $dir/public/java/*
sed -i "s/ip_last/$ip_last_num/g" $dir/java/*
#python项目发布
rm -rf $dir/python
mkdir -p $dir/python
cp -rf /home/config_files/python/* $dir/python/
sed -i "s/target_host_name/${IP_host_first}${ip_last_num}/" $dir/python/*
sed -i "s/ip_last/$ip_last_num/g" $dir/python/*
#node项目发布
rm -rf $dir/node
mkdir -p $dir/node
cp -rf /home/config_files/node/* $dir/node/
cp -rf /home/config_files/node/* $dir/public/node/
sed -i "s/target_host_name/${IP_host_first}${ip_last_num}/" $dir/node/*
sed -i "s/ip_last/$ip_last_num/g" $dir/node/*
sed -i "s/target_host_name:70/${public_ip}:${ip_last_num}/g" $dir/public/node/*
sed -i "s/target_host_name/${IP_host_first}${ip_last_num}/g" $dir/public/node/*
#ui配置发布
rm -rf $dir/ui
mkdir $dir/ui
mkdir -p $dir/public
rm -rf $dir/public/ui
mkdir $dir/public/ui
cp -rf /home/config_files/ui/* $dir/ui/
cp -rf /home/config_files/ui/* $dir/public/ui/
sed -i "s/target_host_name/${IP_host_first}${ip_last_num}/" $dir/ui/*
#if [ $ip_last_num -lt 100 ]; then
# sed -i "s/target_host_name:7/${public_ip}:${ip_last_num}/g" $dir/public/ui/*
#else
sed -i "s/target_host_name:70/${public_ip}:${ip_last_num}/g" $dir/public/ui/*
#fi
sed -i "s/target_host_name/${public_ip}/g" $dir/public/ui/*
sed -i "s/${public_ip}:3306/${IP_host_first}${ip_last_num}:3306/g" $dir/public/ui/*
sed -i "s/ip_last/$ip_last_num/g" $dir/public/ui/*
sed -i "s/ip_last/$ip_last_num/g" $dir/ui/*
#ngxin conf.d发布
rm -rf $dir/nginx_conf.d
mkdir $dir/nginx_conf.d
cp -rf /home/config_files/nginx_conf.d/* $dir/nginx_conf.d/
#baitiao pem发布
rm -rf $dir/pem_file
mkdir $dir/pem_file
cp -rf /home/config_files/pem_file/* $dir/pem_file/
# sed -i "s/target_host_name/${IP_host_first}${ip_last_num}/" $dir/nginx_conf.d/*
echo "结束${IP_host_first}${ip_last_num}"
echo "---------"
done
sh /home/qa-deploy-utils/qa_shell_script/exception_sub_shell.sh
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