install升级到2.5.0 (#157)

This commit is contained in:
阿章 2021-08-03 17:46:26 +08:00 committed by GitHub
parent 5f2bb0caa8
commit 395f932e38
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 10 deletions

2
.gitignore vendored
View File

@ -1,3 +1,3 @@
.DS_Store
docs/.DS_Store
.gitignore
.idea/

20
install
View File

@ -6,6 +6,7 @@ initVar() {
removeType='yum -y remove'
upgrade="yum -y update"
echoType='echo -e'
version='2.5.0'
}
initVar
export LANG=en_US.UTF-8
@ -40,12 +41,11 @@ echoContent() {
esac
}
cd /opt
#首页菜单
menu() {
echoContent red "\n==============================================================\n"
echoContent green "当前版本v2.4.2"
echoContent green "当前版本v${version}"
echoContent green "HFish官网 https://hfish.io "
echoContent red "\n==============================================================\n"
echoContent skyBlue "-------------------------安装部署-----------------------------\n"
@ -81,31 +81,33 @@ menu() {
}
standaloneInstall(){
cd /opt
if [ $(uname -s) = 'Linux' ] && [ $(uname -m) = 'x86_64' ] && [ $(getconf LONG_BIT) = '64' ]; then
wget -N --no-check-certificate http://hfish.cn-bj.ufileos.com/hfish-standalone-2.4.2-linux-amd64.tar.gz
wget -N --no-check-certificate http://hfish.cn-bj.ufileos.com/hfish-standalone-${version}-linux-amd64.tar.gz
elif [ $(uname -m) = 'aarch64' ] && [ $(getconf LONG_BIT) = '64' ]; then
wget -N --no-check-certificate http://hfish.cn-bj.ufileos.com/hfish-standalone-2.4.2-linux-arm64.tar.gz
wget -N --no-check-certificate http://hfish.cn-bj.ufileos.com/hfish-standalone-${version}-linux-arm64.tar.gz
else
echoContent red "未检测到系统版本,请参阅 https://hfish.io 官网文档手动安装!\n" && exit 1
fi
tar -zxvf hfish-standalone*.tar.gz
tar -zxvf /opt/hfish-standalone*.tar.gz
cd /opt/hfish && nohup ./server &
sleep 2
cd /opt/hfish/client && nohup ./client &
}
serverInstall() {
cd /opt
if [ $(uname -s) = 'Linux' ] && [ $(uname -m) = 'x86_64' ] && [ $(getconf LONG_BIT) = '64' ]; then
wget -N --no-check-certificate http://hfish.cn-bj.ufileos.com/hfish-2.4.2-linux-amd64.tar.gz
wget -N --no-check-certificate http://hfish.cn-bj.ufileos.com/hfish-${version}-linux-amd64.tar.gz
elif [ $(uname -m) = 'aarch64' ] && [ $(getconf LONG_BIT) = '64' ]; then
wget -N --no-check-certificate http://hfish.cn-bj.ufileos.com/hfish-2.4.2-linux-arm64.tar.gz
wget -N --no-check-certificate http://hfish.cn-bj.ufileos.com/hfish-${version}-linux-arm64.tar.gz
else
echoContent red "未检测到系统版本,请参阅 https://hfish.io 官网文档手动安装!\n" && exit 1
fi
mkdir -p hfish
tar -zxvf hfish*.tar.gz -C hfish
tar -zxvf /opt/hfish*.tar.gz -C hfish
cd hfish
nohup ./server &
}
@ -124,5 +126,5 @@ exitInstall() {
# echoContent red "未检测到安装目录,请参阅 https://hfish.io 官网文档手动安装!\n" && exit 1
# fi
# }
cd /opt
menu