加入自定义端口选项

pull/2/head
dovela 2018-06-27 00:18:13 +08:00 committed by GitHub
parent c292ef075d
commit b4429203a4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 24 additions and 20 deletions

View File

@ -3,7 +3,7 @@
#================================================= #=================================================
# System Required: CentOS 6+/Debian 6+/Ubuntu 14.04+/others(test) # System Required: CentOS 6+/Debian 6+/Ubuntu 14.04+/others(test)
# Description: Auto-install the ServerStatus Client # Description: Auto-install the ServerStatus Client
# Version: 1.0.1 # Version: 1.0.2
# Author: dovela # Author: dovela
#================================================= #=================================================
@ -38,6 +38,8 @@ debian_apt(){
install_sss(){ install_sss(){
clear clear
stty erase '^H' && read -p " 服务端地址:" sserver stty erase '^H' && read -p " 服务端地址:" sserver
stty erase '^H' && read -p " 远程端口默认35601:" sport
[[ -z ${sport} ]] && sport="35601"
stty erase '^H' && read -p " 客户端username:" suser stty erase '^H' && read -p " 客户端username:" suser
stty erase '^H' && read -p " 客户端password:" spasswd stty erase '^H' && read -p " 客户端password:" spasswd
clear clear
@ -46,9 +48,11 @@ install_sss(){
echo 'ServerStatus客户端安装完成' echo 'ServerStatus客户端安装完成'
cd ServerStatus/clients cd ServerStatus/clients
sed -i -e "s/sserver/$sserver/g" client-linux.py sed -i -e "s/sserver/$sserver/g" client-linux.py
sed -i -e "s/sport/$sport/g" client-linux.py
sed -i -e "s/suser/$suser/g" client-linux.py sed -i -e "s/suser/$suser/g" client-linux.py
sed -i -e "s/spasswd/$spasswd/g" client-linux.py sed -i -e "s/spasswd/$spasswd/g" client-linux.py
sed -i -e "s/sserver/$sserver/g" client-psutil.py sed -i -e "s/sserver/$sserver/g" client-psutil.py
sed -i -e "s/sport/$sport/g" client-psutil.py
sed -i -e "s/suser/$suser/g" client-psutil.py sed -i -e "s/suser/$suser/g" client-psutil.py
sed -i -e "s/spasswd/$spasswd/g" client-psutil.py sed -i -e "s/spasswd/$spasswd/g" client-psutil.py
clear clear