Commit 0aa36b61 authored by tywldx's avatar tywldx
parents 3cd5ce12 e7a639ae
...@@ -5,5 +5,7 @@ ...@@ -5,5 +5,7 @@
*.swl *.swl
*.swm *.swm
*.swk *.swk
*.log
.DS_Store .DS_Store
qa_shell_script/config_server/node_modules qa_shell_script/config_server/node_modules
.log
# -------------------------------------------------------------------------------
# Filename: db_replace_ip.sh
# Revision: 1.1
# Date: 2017/02
# Author: dekun.dai
# Description: 该脚本根据备份sql称特定环境使用的sql
# Usage:used by ../deploy/db_replace_ip.sh
# -------------------------------------------------------------------------------
database_name=$1
server_host=$2
db_sub_backup_folder=$3
re_replace_ip=$4
public_ip="www.q-gp.com"
ip_last=$5
pwd_path="/home/qa-deploy-utils/qa_shell_script"
config_server="$pwd_path/config_server"
echo $server_host
cd $db_sub_backup_folder
file_count=`ls -l |grep "^-"|wc -l`
function trancsHostName()
{
if [ "$4" = true ]; then
sed -i "s/$2/$3-$7.q-gp.com/g" $5
else
sed -i "s/$2/$6:$1/g" $5
fi
}
echo "./* file count is $file_count"
if [ "$file_count" -gt 0 ]; then
for entry in ./*
do
sed -i "s/https/http/g" $entry
echo "is replace ip for db_back_file $entry"
var=`cat $config_server/get_project_host.sh`
for v in ${var[@]}
do
i=${v//|/ }
trancsHostName i $re_replace_ip $entry ${server_host} ${ip_last}
done
done
fi
...@@ -129,6 +129,10 @@ elif [[ $database_name = 'xyqb_btzt' ]]; then ...@@ -129,6 +129,10 @@ elif [[ $database_name = 'xyqb_btzt' ]]; then
sys_table_list='zt_channel zt_fund zt_fund_channel zt_fund_credit zt_fund_term' sys_table_list='zt_channel zt_fund zt_fund_channel zt_fund_credit zt_fund_term'
source_db_host='192.168.4.116' source_db_host='192.168.4.116'
port='7001' port='7001'
elif [[ $database_name = 'user_credit' ]]; then
# user_credit
sys_table_list=''
port='9001'
elif [[ $database_name = 'notify' ]]; then elif [[ $database_name = 'notify' ]]; then
# 通知 # 通知
sys_table_list='merchant merchant_config' sys_table_list='merchant merchant_config'
......
File mode changed from 100644 to 100755
File mode changed from 100644 to 100755
...@@ -102,8 +102,8 @@ function run_sql_file() ...@@ -102,8 +102,8 @@ function run_sql_file()
sh $work_dir/db_execute_sql.sh $target_db_host $sync_db_name sh $work_dir/db_execute_sql.sh $target_db_host $sync_db_name
} }
database_list='cash_loan_flow contract dujiangyan financial_system financial_system_api fund_manage gyxd mall merchant notify offline payment_center qinqiong quartz redpacket risk_control silk_road spider_center xyqb xyqb_app xyqb_btzt xyqb_user' database_list='cash_loan_flow contract dujiangyan financial_system financial_system_api fund_manage gyxd mall merchant notify offline payment_center qinqiong quartz redpacket risk_control silk_road spider_center user_credit xyqb xyqb_app xyqb_btzt xyqb_user'
database_list2='cash_loan_flow contract dujiangyan financial_system financial_system_api fund_manage gyxd merchant notify offline payment_center qinqiong quartz redpacket risk_control silk_road spider_center xyqb xyqb_app xyqb_btzt xyqb_user' database_list2='cash_loan_flow contract dujiangyan financial_system financial_system_api fund_manage gyxd merchant notify offline payment_center qinqiong quartz redpacket risk_control silk_road spider_center user_credit xyqb xyqb_app xyqb_btzt xyqb_user'
if [[ "$sync_db_name" = "all" ]] if [[ "$sync_db_name" = "all" ]]
then then
echo "sync all database schema" echo "sync all database schema"
......
...@@ -80,7 +80,7 @@ new pClass().init(1,true, "java", "7023", "quartz", "xyqb-quartz", "QG", "quartz ...@@ -80,7 +80,7 @@ new pClass().init(1,true, "java", "7023", "quartz", "xyqb-quartz", "QG", "quartz
new pClass().init(2,true,"java", "7021", "scapi", "spider-center", "QG", "spider-center.log", "application.properties", "--worker 1 --currentWorker 1 -t -ts > /dev/null 2>&1 &", null, 2, "授信-server", "", "mvn clean package -Ptest -Dmaven.test.skip=true", ""); new pClass().init(2,true,"java", "7021", "scapi", "spider-center", "QG", "spider-center.log", "application.properties", "--worker 1 --currentWorker 1 -t -ts > /dev/null 2>&1 &", null, 2, "授信-server", "", "mvn clean package -Ptest -Dmaven.test.skip=true", "");
new pClass().init(1,true,"java", "7037", "qapi", "cash-loan-flow", "QG", "cash_loan_flow.log", "application.properties", "--worker 1 --currentWorker 1 -t -ts > /dev/null 2>&1 &", null, 2, "现金贷流量对接-server", "", "mvn clean package -Ptest -Dmaven.test.skip=true", ""); new pClass().init(1,true,"java", "7037", "qapi", "cash-loan-flow", "QG", "cash_loan_flow.log", "application.properties", "--worker 1 --currentWorker 1 -t -ts > /dev/null 2>&1 &", null, 2, "现金贷流量对接-server", "", "mvn clean package -Ptest -Dmaven.test.skip=true", "");
new pClass().init(1,true, "java", "7012", "financial-api", "financial-system", "QG", "financial_system.log", "application.properties", "--worker 1 --currentWorker 1 -t -ts > /dev/null 2>&1 &", null, 2, "财务系统-server", "", "mvn clean package -Ptest -Dmaven.test.skip=true", ""); new pClass().init(1,true, "java", "7012", "financial-api", "financial-system", "QG", "financial_system.log", "application.properties", "--worker 1 --currentWorker 1 -t -ts > /dev/null 2>&1 &", null, 2, "财务系统-server", "", "mvn clean package -Ptest -Dmaven.test.skip=true", "");
new pClass().init(2,false, "java", "7034", "", "fund-manage", "QG", "fund_manage.log", "application.properties", "--worker 1 --currentWorker 1 -t -ts > /dev/null 2>&1 &", null, 2, "债转系统-server", "", "mvn clean package -Ptest -Dmaven.test.skip=true", ""); new pClass().init(1,false, "java", "7034", "", "fund-manage", "QG", "fund_manage.log", "application.properties", "--worker 1 --currentWorker 1 -t -ts > /dev/null 2>&1 &", null, 2, "债转系统-server", "", "mvn clean package -Ptest -Dmaven.test.skip=true", "");
new pClass().init(1,false,"java", "7029", "gyxdapi", "gyxd", "QG", "gyxd.log", "application.properties", "--worker 1 --currentWorker 1 -t -ts > /dev/null 2>&1 &", null, 2, "广源小贷-server", "", "mvn clean package -Ptest -Dmaven.test.skip=true", ""); new pClass().init(1,false,"java", "7029", "gyxdapi", "gyxd", "QG", "gyxd.log", "application.properties", "--worker 1 --currentWorker 1 -t -ts > /dev/null 2>&1 &", null, 2, "广源小贷-server", "", "mvn clean package -Ptest -Dmaven.test.skip=true", "");
new pClass().init(1,true, "java", "7038", "merchantapi", "merchant-backend", "QG", "merchant.log", "application.properties", "--worker 1 --currentWorker 1 -t -ts > /dev/null 2>&1 &", null, 2, "商户后台-server", "凌子华/陈东亮", "mvn clean package -Ptest -Dmaven.test.skip=true", ""); new pClass().init(1,true, "java", "7038", "merchantapi", "merchant-backend", "QG", "merchant.log", "application.properties", "--worker 1 --currentWorker 1 -t -ts > /dev/null 2>&1 &", null, 2, "商户后台-server", "凌子华/陈东亮", "mvn clean package -Ptest -Dmaven.test.skip=true", "");
new pClass().init(1,true,"java", "7031", "redpacket", "redpacket", "baitiao", "redpacket.log", "application.properties", "--worker 1 --currentWorker 1 -t > /dev/null 2>&1 &", null, 2, "红包系统-server", "", "mvn clean package -Ptest -Dmaven.test.skip=true", ""); new pClass().init(1,true,"java", "7031", "redpacket", "redpacket", "baitiao", "redpacket.log", "application.properties", "--worker 1 --currentWorker 1 -t > /dev/null 2>&1 &", null, 2, "红包系统-server", "", "mvn clean package -Ptest -Dmaven.test.skip=true", "");
...@@ -141,7 +141,7 @@ new pClass().init(1,true, "ui", "7070", "", "customer-op-ui", "ui", null, "src/c ...@@ -141,7 +141,7 @@ new pClass().init(1,true, "ui", "7070", "", "customer-op-ui", "ui", null, "src/c
new pClass().init(1,true, "ui", "7075", "", "business-op-ui", "ui", null, "src/config/env.config.js", "npm run build", "node7", 1, "商城结算系统-ui", "王丽英", "", ""); new pClass().init(1,true, "ui", "7075", "", "business-op-ui", "ui", null, "src/config/env.config.js", "npm run build", "node7", 1, "商城结算系统-ui", "王丽英", "", "");
new pClass().init(2,true, "ui", "7077", "", "cuishou-ui-new", "data", null, "src/Config/config.jsx", "npm run dist", "node7", 1, "催收系统-ui", "李斌", "", ""); new pClass().init(2,true, "ui", "7077", "", "cuishou-ui-new", "data", null, "src/Config/config.jsx", "npm run dist", "node7", 1, "催收系统-ui", "李斌", "", "");
new pClass().init(1,true, "ui", "7078", "", "ka-factory-ui", "ui", null, "src/config/env.config.js", "npm run build", "node7", 1, "KA工厂-ui", "张振武", "", ""); new pClass().init(1,true, "ui", "7078", "", "ka-factory-ui", "ui", null, "src/config/env.config.js", "npm run build", "node7", 1, "KA工厂-ui", "张振武", "", "");
new pClass().init(1,true, "ui", "7064", "statistics-op", "statistics-op-ui", "ui", null, "src/app/config/env.config.js", "npm run qa", "node7", 1, "流量统计平台-ui", "刘威", "", ""); new pClass().init(1,false, "ui", "7064", "statistics-op", "statistics-op-ui", "ui", null, "src/app/config/env.config.js", "npm run qa", "node7", 1, "流量统计平台-ui", "刘威", "", "");
new pClass().init(1,true, "ui", "7080", "", "new-mall-ui", "ui", null, "src/app/config/env.config.js", "npm run qa", "node7", 1, "微信商城-ui", "郑少文,周珊", "", ""); new pClass().init(1,true, "ui", "7080", "", "new-mall-ui", "ui", null, "src/app/config/env.config.js", "npm run qa", "node7", 1, "微信商城-ui", "郑少文,周珊", "", "");
// node // node
......
...@@ -9,6 +9,7 @@ ...@@ -9,6 +9,7 @@
"author": "", "author": "",
"license": "ISC", "license": "ISC",
"dependencies": { "dependencies": {
"body-parser": "^1.18.2",
"child_process": "^1.0.2", "child_process": "^1.0.2",
"express": "^4.16.2", "express": "^4.16.2",
"pm2": "^2.7.2" "pm2": "^2.7.2"
......
...@@ -84,6 +84,14 @@ tranceConfig ui "wx89894cd83d117b26" "wx5b2e77c58fdcf1a5" "192.168.4.24" "activi ...@@ -84,6 +84,14 @@ tranceConfig ui "wx89894cd83d117b26" "wx5b2e77c58fdcf1a5" "192.168.4.24" "activi
#tranceConfig java "pay.debug=0" "pay.debug=1" "192.168.4.14" "xyqb-mall.properties" #tranceConfig java "pay.debug=0" "pay.debug=1" "192.168.4.14" "xyqb-mall.properties"
tranceConfig java "www.q-gp.com:1462" "192.168.4.14:7062" "192.168.4.14" "xyqb-user2.properties" tranceConfig java "www.q-gp.com:1462" "192.168.4.14:7062" "192.168.4.14" "xyqb-user2.properties"
tranceConfig java "www.q-gp.com:2181" "192.168.4.14:2181" "192.168.4.14" "xyqb-user2.properties" tranceConfig java "www.q-gp.com:2181" "192.168.4.14:2181" "192.168.4.14" "xyqb-user2.properties"
tranceConfig ui "wechattest.xyqb.com" "xyqb-user2-14.q-gp.com" "192.168.4.14" "xyqb-user-ui.js"
tranceConfig java "wx89894cd83d117b26" "wxc94ca68b353e90d0" "192.168.4.14" "xyqb-user2.properties"
tranceConfig java "11fb7f6a8b8edf2776a72c2f5624229c" "e30380e9ade07f361e51a643f94d8817" "192.168.4.14" "xyqb-user2.properties"
tranceConfig ui "wx89894cd83d117b26" "wxc94ca68b353e90d0" "192.168.4.14" "xyqb-user-ui.js"
tranceConfig java "192.168.4.14:7043" "xyqb-user-ui-14.q-gp.com" "192.168.4.14" "xyqb-user2.properties"
tranceConfig ui "wechattest.xyqb.com" "xyqb-user2-14.q-gp.com" "192.168.4.14" "new-xyqb-user-ui.js"
tranceConfig ui "wx89894cd83d117b26" "wxc94ca68b353e90d0" "192.168.4.14" "new-xyqb-user-ui.js"
#4.15 #4.15
#tranceConfig java "192.168.4.15:7007" "139.198.2.95:1507" "192.168.4.15" "gu-bei.properties" #tranceConfig java "192.168.4.15:7007" "139.198.2.95:1507" "192.168.4.15" "gu-bei.properties"
...@@ -167,7 +175,7 @@ tranceConfig java "wx.api_host=https:\/\/api.mch.weixin.qq.com\/" "wx.api_host=h ...@@ -167,7 +175,7 @@ tranceConfig java "wx.api_host=https:\/\/api.mch.weixin.qq.com\/" "wx.api_host=h
#tranceConfig node ":7013/app/login" ":7042/app/login2" "192.168.4.72" "AppBackend.js" #tranceConfig node ":7013/app/login" ":7042/app/login2" "192.168.4.72" "AppBackend.js"
#tranceConfig node ":7013" ":7042" "192.168.4.72" "AppBackend.js" #tranceConfig node ":7013" ":7042" "192.168.4.72" "AppBackend.js"
#tranceConfig java "wx.api_host=https:\/\/api.mch.weixin.qq.com\/" "wx.api_host=http:\/\/mock.q-gp.com\/" "192.168.4.72" "gu-bei.properties" #tranceConfig java "wx.api_host=https:\/\/api.mch.weixin.qq.com\/" "wx.api_host=http:\/\/mock.q-gp.com\/" "192.168.4.72" "gu-bei.properties"
tranceConfig node "http://139.198.2.95:38099" "http://192.168.4.48:8099" "192.168.4.72" "AppBackend.js"
#4.151 #4.151
tranceConfig java "xyqb.is.debug=0" "xyqb.is.debug=1" "192.168.4.151" "xyqb.properties" tranceConfig java "xyqb.is.debug=0" "xyqb.is.debug=1" "192.168.4.151" "xyqb.properties"
tranceConfig java "liebao.aes.key=0123456789abcdef" "liebao.aes.key=e2XNtnB8QEEuvhEW" "192.168.4.151" "cash-loan-flow.properties" tranceConfig java "liebao.aes.key=0123456789abcdef" "liebao.aes.key=e2XNtnB8QEEuvhEW" "192.168.4.151" "cash-loan-flow.properties"
......
...@@ -61,13 +61,13 @@ addFrpcLoc local_ http 8000 q-gp.com / $filename ...@@ -61,13 +61,13 @@ addFrpcLoc local_ http 8000 q-gp.com / $filename
addFrpcSub store http 127.0.0 1 8001 store $filename addFrpcSub store http 127.0.0 1 8001 store $filename
addFrpcSub h5 http 192.168.4 26 7051 h5 $filename addFrpcSub h5 http 192.168.4 25 7051 h5 $filename
addFrpcSub mock http 172.30.199 2 80 mock $filename addFrpcSub mock http 192.168.4 27 80 mock $filename
addFrpcSub atm http 192.168.4 18 3000 atm $filename addFrpcSub atm http 192.168.4 18 3000 atm $filename
addFrpcSub auth-center http 192.168.4 193 8099 auth-center-38 $filename addFrpcSub auth-center http 192.168.4 193 8099 auth-center-38 $filename
addFrpcSub company http 172.30.199 2 10087 company-241 $filename addFrpcSub company http 192.168.4 27 10087 company-241 $filename
addFrpcSub bp http 172.30.199 2 10084 bp $filename addFrpcSub bp http 192.168.4 27 10084 bp $filename
addFrpcSub qahelp http 172.30.199 2 8000 qahelp $filename addFrpcSub qahelp http 192.168.4 27 8000 qahelp $filename
...@@ -148,7 +148,7 @@ function createNginxHttpAndSSLConf() ...@@ -148,7 +148,7 @@ function createNginxHttpAndSSLConf()
rm -rf $nginxname/* rm -rf $nginxname/*
createNginxSSLConf store 172.30.199.2 9000 $nginxname/store.conf createNginxSSLConf store 192.168.4.27 9000 $nginxname/store.conf
for ip_last in ${ips[@]} for ip_last in ${ips[@]}
do do
......
#!/bin/bash
ip=$1
phone_no=$2
num=$3 #激活白条的数量
merchant_id=$4 #渠道编号
bill_num_a=0
PORT="3306"
USERNAME="qa"
PASSWORD="qatest"
mysqld="-h${ip} -P${PORT} -u${USERNAME} -p${PASSWORD}"
date_now=`date "+%Y-%m-%d %H:%M:%S"`
function activate()
{
len=`echo $phone_no|awk '{print length($0)}'`
if [ $len -ne 11 ] ; then
echo "请输入11位手机号 !"
else
if [ -z $num ];then
num=1
fi
if [ -z ${merchant_id} ];then
merchant_id=7
fi
i=0
while [ $i -lt $num ]; do
uuid='928ba526-29f1-4ef8-8bb8-'${phone_no}
insert_xyqb_user="INSERT INTO user( "phone_no", "password", "registered_from", "uuid", "enable", "created_at", "updated_at")VALUES ( ${phone_no}, '318e235d3e52648b236faa3f748000d5', '214', '${uuid}', '1', '$date_now', '$date_now')"
mysql $mysqld xyqb_user -e "set names utf8;${insert_xyqb_user}"
select_user_id="SELECT id from user where user.phone_no=${phone_no}"
xyqb_user_id=`mysql -N $mysqld xyqb_user -e "set names utf8;${select_user_id}"`
#:用户信息表增加数据
insert_user_detail="INSERT INTO user_detail("user_id", "phone_no", "name", "id_no", "id_type", "is_authenticated", "gender", "email", "qq", "created_at", "updated_at")VALUES (${xyqb_user_id}, ${phone_no}, '滕尘', '532523198811050620', 0, 0, 1, '', 'undefined', '$date_now', '$date_now')"
mysql $mysqld xyqb_user -e "set names utf8;${insert_user_detail}"
# 贷款记录表增加数据
insert_history="INSERT INTO loan_application_history ("user_id", "channel_id", "bank_card_id", "is_active", "progress", "created_from", "business_type", "pay_approach", "baitiao_merchant_id", "created_at", "updated_at")VALUES (${xyqb_user_id}, 222, 100, 1, 39, 222, 1, NULL, ${merchant_id}, '${date_now}', '${date_now}')"
mysql $mysqld xyqb -e "set names utf8;${insert_history}"
#激活记录表增加数据
insert_step_info="INSERT INTO loan_step_info ("user_id", "merchant_id", "status_code", "created_at")VALUES (${xyqb_user_id}, ${merchant_id}, 0, '$date_now'), (${xyqb_user_id}, ${merchant_id}, 5, '$date_now')"
mysql $mysqld xyqb -e "set names utf8;${insert_step_info}"
#白条额度表修改数据
insert_account="INSERT INTO baitiao_account( "user_id", "registered_from", "pay_pwd", "pay_pwd_salt", "credit_amount", "status", "created_at", "updated_at")VALUES ( ${xyqb_user_id}, ${merchant_id}, '55cfe3b492c6528ef2ba27a52b439a93', 'Q0I0QTQzRjcxNTExMDUyQjAwNTY2MTI2', '16000.00', '1', '$date_now', '$date_now')"
mysql $mysqld xyqb -e "set names utf8;${insert_account}"
#白条额度变化表增加数据
consume_seq='XYBT201708051511458'${phone_no}
insert_consume="INSERT INTO baitiao_consume_history ("user_id", "order_id", "order_amount", "remaining_amount", "consume_type", "consume_seq", "created_at", "updated_at")VALUES (${xyqb_user_id}, -1, 16000.00, 16000.00, 0, '${consume_seq}','$date_now', '$date_now' )"
mysql $mysqld xyqb -e "set names utf8;${insert_consume}"
#授信用户表
uuid1='69891c47-e8c7-4b96-8a8d-'${phone_no}
insert_spider="INSERT INTO user ("phone_no", "password", "registered_from", "uuid", "enable", "created_at", "updated_at")VALUES (${phone_no}, '4c00961baa8857e558c10db0e58c003e', 222, '${uuid1}', 1, '$date_now', '$date_now')"
mysql $mysqld spider_center -e "set names utf8;${insert_spider}"
#授权表增加数据
select_spider_user_id="select id FROM user WHERE user.phone_no=${phone_no}"
spider_user_id=`mysql -N $mysqld spider_center -e "${select_spider_user_id}"`
insert_authorization="INSERT INTO user_authorization ("auth_type", "last_auth_time", "auth_account_name", "user_id", "auth_status")VALUES(0, '$date_now', NULL, ${spider_user_id}, 1),(3, '$date_now', NULL, ${spider_user_id}, 1)"
mysql $mysqld spider_center -e "set names utf8;${insert_authorization}"
#mall用户表
uuid2='3a324e8b-78dc-45a7-bf16-'${phone_no}
insert_mall="INSERT INTO user("phone_no", "password", "registered_from", "uuid", "enable", "created_at", "updated_at")VALUES ( ${phone_no}, '318e235d3e52648b236faa3f748000d5', '214', '${uuid2}', '1', '$date_now', '$date_now')"
mysql $mysqld mall -e "set names utf8;${insert_mall}"
select_mall_user_id="select id FROM user WHERE phone_no=${phone_no}"
mall_user_id=`mysql -N $mysqld mall -e "${select_mall_user_id}"`
insert_mall_user_detail="INSERT INTO user_detail ( "user_id", "phone_no", "name", "id_no", "id_type", "is_authenticated", "gender", "created_at", "updated_at")VALUES (${mall_user_id}, ${phone_no}, '滕尘', '532523198811050620', '0', '0', '1', '$date_now', '$date_now')"
mysql $mysqld mall -e "set names utf8;${insert_mall_user_detail}"
#mall.baitiao_card
insert_mall_card="INSERT INTO baitiao_card ( "user_id", "phone_no", "baitiao_activate_status", "created_at", "updated_at", "available_credit", "overdue_qgbc", "overdue_xyqb", "credit_enough", "next_redirect", "risk_control_message", "original_credit", "pass_risk_control")VALUES ( ${mall_user_id}, ${phone_no}, '2', '$date_now', '$date_now', '16000.00', '0', '0', '1', NULL,NULL, '16000.00', '1')"
mysql $mysqld mall -e "set names utf8;${insert_mall_card}"
i=$(( $i + 1 ))
phone_no=$(( $phone_no + 1 ))
done
if [ $i -eq $num ];then
echo "successful done! `date`"
else
echo "failed! `date` 建议输入合适的手机号基数"
fi
fi
}
activate $ip $phone_no $num $merchant_id
...@@ -48,6 +48,10 @@ ssh root@192.168.4.3 "sed -i \"s#weixinAppid:.*#weixinAppid:\'$dev_appid\',#g\" ...@@ -48,6 +48,10 @@ ssh root@192.168.4.3 "sed -i \"s#weixinAppid:.*#weixinAppid:\'$dev_appid\',#g\"
ssh root@192.168.4.3 "sed -i \"s#weixinAppid:.*#weixinAppid:\'$dev_appid\',#g\" $base_path/$env_ip/public/ui/xyqb-user-ui.js" ssh root@192.168.4.3 "sed -i \"s#weixinAppid:.*#weixinAppid:\'$dev_appid\',#g\" $base_path/$env_ip/public/ui/xyqb-user-ui.js"
ssh root@192.168.4.3 "sed -i \"s#wechattest.xyqb.com#$user_url#g\" $base_path/$env_ip/ui/xyqb-user-ui.js" ssh root@192.168.4.3 "sed -i \"s#wechattest.xyqb.com#$user_url#g\" $base_path/$env_ip/ui/xyqb-user-ui.js"
ssh root@192.168.4.3 "sed -i \"s#wechattest.xyqb.com#$user_url#g\" $base_path/$env_ip/public/ui/xyqb-user-ui.js" ssh root@192.168.4.3 "sed -i \"s#wechattest.xyqb.com#$user_url#g\" $base_path/$env_ip/public/ui/xyqb-user-ui.js"
ssh root@192.168.4.3 "sed -i \"s#weixinAppid:.*#weixinAppid:\'$dev_appid\',#g\" $base_path/$env_ip/ui/new-xyqb-user-ui.js"
ssh root@192.168.4.3 "sed -i \"s#weixinAppid:.*#weixinAppid:\'$dev_appid\',#g\" $base_path/$env_ip/public/ui/new-xyqb-user-ui.js"
ssh root@192.168.4.3 "sed -i \"s#wechattest.xyqb.com#$user_url#g\" $base_path/$env_ip/ui/new-xyqb-user-ui.js"
ssh root@192.168.4.3 "sed -i \"s#wechattest.xyqb.com#$user_url#g\" $base_path/$env_ip/public/ui/new-xyqb-user-ui.js"
echo "step 2 重新部署环境" echo "step 2 重新部署环境"
function reBuildProject(){ function reBuildProject(){
expect -c " expect -c "
...@@ -68,6 +72,7 @@ function reBuildProject(){ ...@@ -68,6 +72,7 @@ function reBuildProject(){
expect eof;" expect eof;"
} }
reBuildProject "xyqb-user-ui" "$env_ip" reBuildProject "xyqb-user-ui" "$env_ip"
reBuildProject "new-xyqb-user-ui" "$evn_ip"
reBuildProject "xyqb-user2" "$env_ip" reBuildProject "xyqb-user2" "$env_ip"
reBuildProject "xyqb" "$env_ip" reBuildProject "xyqb" "$env_ip"
echo "部署结束,如果之后修改代码,部署project后,请重新执行该部署脚本,否则有可能出现测试环境配置文件被回退的可能。" echo "部署结束,如果之后修改代码,部署project后,请重新执行该部署脚本,否则有可能出现测试环境配置文件被回退的可能。"
......
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