Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qa-deploy-utils
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
QA
qa-deploy-utils
Commits
a96d5d1a
Commit
a96d5d1a
authored
May 26, 2017
by
智勇
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
每周更新
parent
12dd0d18
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
37 additions
and
50 deletions
+37
-50
db_schema_sync.sh
db-utils/db_schema_sync.sh
+1
-1
.exception_sub_shell.sh.swp
qa_shell_script/.exception_sub_shell.sh.swp
+0
-0
2_get_code_by_type.sh
qa_shell_script/2_get_code_by_type.sh
+17
-10
exception_sub_shell.sh
qa_shell_script/exception_sub_shell.sh
+14
-11
initial_mq.sh
qa_shell_script/rabbitmq/initial_mq.sh
+4
-0
sub_shell.sh
qa_shell_script/sub_shell.sh
+1
-1
remote_excute_new.sh
remote_excute_new.sh
+0
-27
No files found.
db-utils/db_schema_sync.sh
View file @
a96d5d1a
...
...
@@ -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
"
...
...
qa_shell_script/.exception_sub_shell.sh.swp
0 → 100644
View file @
a96d5d1a
File added
qa_shell_script/2_get_code_by_type.sh
View file @
a96d5d1a
...
...
@@ -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
qa_shell_script/exception_sub_shell.sh
View file @
a96d5d1a
...
...
@@ -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"
qa_shell_script/rabbitmq/initial_mq.sh
View file @
a96d5d1a
...
...
@@ -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
...
...
qa_shell_script/sub_shell.sh
View file @
a96d5d1a
#!/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
`
...
...
remote_excute_new.sh
deleted
100755 → 0
View file @
12dd0d18
#!/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
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment