diff --git a/plugins/caddy/versions/2.11/install.sh b/plugins/caddy/versions/2.11/install.sh index 38911cdc0..ba4bae8c9 100644 --- a/plugins/caddy/versions/2.11/install.sh +++ b/plugins/caddy/versions/2.11/install.sh @@ -60,7 +60,7 @@ Install_App() mkdir -p cd $serverPath/source/caddy/caddy cd $serverPath/source/caddy/caddy && tar -zxvf ${caddyDir}/$FILE_NAME - if [ "$OSNAME" == "mac" ];then + if [ "$OSNAME" = "mac" ];then xattr -cr caddy fi diff --git a/plugins/dynamic-tracking/install.sh b/plugins/dynamic-tracking/install.sh index 996a4da8c..ad75f9d44 100755 --- a/plugins/dynamic-tracking/install.sh +++ b/plugins/dynamic-tracking/install.sh @@ -19,7 +19,7 @@ fi OSNAME=`bash ${rootPath}/scripts/getos.sh` -if [ "" == "$OSNAME" ];then +if [ "" = "$OSNAME" ];then OSNAME=`cat ${rootPath}/data/osname.pl` fi diff --git a/plugins/dztasks/install.sh b/plugins/dztasks/install.sh index 5d77e72c0..621d66cc2 100755 --- a/plugins/dztasks/install.sh +++ b/plugins/dztasks/install.sh @@ -14,16 +14,16 @@ sysArch=`arch` sysName=`uname` DZ_ARCH_NAME=amd64 -if [ "$sysArch" == "arm64" ];then +if [ "$sysArch" = "arm64" ];then DZ_ARCH_NAME=arm64 -elif [ "$sysArch" == "x86_64" ]; then +elif [ "$sysArch" = "x86_64" ]; then DZ_ARCH_NAME=amd64 -elif [ "$sysArch" == "aarch64" ]; then +elif [ "$sysArch" = "aarch64" ]; then DZ_ARCH_NAME=aarch64 fi DZ_NAME=linux -if [ "$sysName" == "Darwin" ];then +if [ "$sysName" = "Darwin" ];then DZ_NAME=darwin fi Install_App() diff --git a/plugins/gitea/install.sh b/plugins/gitea/install.sh index d34a8dd26..a2353011a 100755 --- a/plugins/gitea/install.sh +++ b/plugins/gitea/install.sh @@ -25,11 +25,11 @@ getBit(){ } Install_Rsync(){ - if [ "$OSNAME" == "debian" ] || [ "$OSNAME" == "ubuntu" ];then + if [ "$OSNAME" = "debian" ] || [ "$OSNAME" = "ubuntu" ];then apt install -y rsync - elif [[ "$OSNAME" == "arch" ]]; then + elif [[ "$OSNAME" = "arch" ]]; then echo y | pacman -Sy rsync - elif [[ "$OSNAME" == "macos" ]]; then + elif [[ "$OSNAME" = "macos" ]]; then # brew install rsync # brew install lsyncd echo "ok" @@ -119,7 +119,7 @@ Uninstall_App() action=$1 version=$2 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_App $version else Uninstall_App $version diff --git a/plugins/gogs/install.sh b/plugins/gogs/install.sh index e572a200f..bb3f992c7 100755 --- a/plugins/gogs/install.sh +++ b/plugins/gogs/install.sh @@ -16,7 +16,7 @@ GOGS_DOWNLOAD='https://dl.gogs.io' getOs(){ os=`uname` - if [ "Darwin" == "$os" ];then + if [ "Darwin" = "$os" ];then echo 'darwin' else echo 'linux' @@ -100,7 +100,7 @@ Uninstall_gogs() action=$1 version=$2 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_gogs $version else Uninstall_gogs $version diff --git a/plugins/gorse/install.sh b/plugins/gorse/install.sh index 3edbb195e..447341b92 100755 --- a/plugins/gorse/install.sh +++ b/plugins/gorse/install.sh @@ -21,16 +21,16 @@ Install_App() mkdir -p $serverPath/source/gorse SYSNAME=linux - if [ "$sysName" == "Darwin" ];then + if [ "$sysName" = "Darwin" ];then SYSNAME=darwin fi ARCH="amd64" - if [ "$sysArch" == "x86_64" ];then + if [ "$sysArch" = "x86_64" ];then ARCH="amd64" - elif [ "$sysArch" == "aarch64" ];then + elif [ "$sysArch" = "aarch64" ];then ARCH="arm64" - elif [ "$sysArch" == "arm64" ];then + elif [ "$sysArch" = "arm64" ];then ARCH="arm64" else ARCH="amd64" @@ -88,7 +88,7 @@ Uninstall_App() } action=$1 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_App else Uninstall_App diff --git a/plugins/keepalived/scripts/chk.sh b/plugins/keepalived/scripts/chk.sh index 432b5a1ef..c1a565257 100644 --- a/plugins/keepalived/scripts/chk.sh +++ b/plugins/keepalived/scripts/chk.sh @@ -11,7 +11,7 @@ rootPath=$(dirname "$curPath") SOFT=$1 -if [ "$SOFT" == "mysql" ];then +if [ "$SOFT" = "mysql" ];then bash ${rootPath}/keepalived/scripts/chk_mysql.sh > ${rootPath}/keepalived/keepalived.log else echo "you should use [chk.sh mysql] exp ." diff --git a/plugins/mariadb/versions/11.7/install.sh b/plugins/mariadb/versions/11.7/install.sh index b3f7bfc59..060c09c7e 100755 --- a/plugins/mariadb/versions/11.7/install.sh +++ b/plugins/mariadb/versions/11.7/install.sh @@ -113,7 +113,7 @@ Uninstall_app() } action=$1 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_app else Uninstall_app diff --git a/plugins/mariadb/versions/12.0/install.sh b/plugins/mariadb/versions/12.0/install.sh index e8506c674..394014779 100755 --- a/plugins/mariadb/versions/12.0/install.sh +++ b/plugins/mariadb/versions/12.0/install.sh @@ -113,7 +113,7 @@ Uninstall_app() } action=$1 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_app else Uninstall_app diff --git a/plugins/mariadb/versions/12.1/install.sh b/plugins/mariadb/versions/12.1/install.sh index 2cf9a7bc1..df28b54ec 100755 --- a/plugins/mariadb/versions/12.1/install.sh +++ b/plugins/mariadb/versions/12.1/install.sh @@ -113,7 +113,7 @@ Uninstall_app() } action=$1 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_app else Uninstall_app diff --git a/plugins/mongodb/versions/4.4/centos.sh b/plugins/mongodb/versions/4.4/centos.sh index 2129b4d82..f8a52e340 100644 --- a/plugins/mongodb/versions/4.4/centos.sh +++ b/plugins/mongodb/versions/4.4/centos.sh @@ -89,11 +89,11 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${TOOL_FILE_NAME} #--------------- mongodb database install ------------------ # TOOL_VERSION=100.9.4 TOOL_FILE_NAME=mongodb-database-tools-rhel${SYS_NAME}-x86_64-${TOOL_VERSION} -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-rhel${SYS_NAME}-aarch64-${TOOL_VERSION} fi -if [ "arm64" == ${SYS_ARCH} ];then +if [ "arm64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-rhel${SYS_NAME}-arm64-${TOOL_VERSION} fi diff --git a/plugins/mongodb/versions/5.0/debian.sh b/plugins/mongodb/versions/5.0/debian.sh index 2a58e1980..978fc7068 100644 --- a/plugins/mongodb/versions/5.0/debian.sh +++ b/plugins/mongodb/versions/5.0/debian.sh @@ -47,7 +47,7 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${FILE_NAME} #--------------- mongosh tool install ------------------ # TOOL_VERSION=2.2.5 TOOL_FILE_NAME=mongosh-${TOOL_VERSION}-linux-x64 -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongosh-${TOOL_VERSION}-linux-arm64 fi TOOL_FILE_NAME_TGZ=${TOOL_FILE_NAME}.tgz @@ -66,11 +66,11 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${TOOL_FILE_NAME} #--------------- mongodb database install ------------------ # TOOL_VERSION=100.9.4 TOOL_FILE_NAME=mongodb-database-tools-debian${SYS_NAME}-x86_64-${TOOL_VERSION} -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-debian${SYS_NAME}-arm64-${TOOL_VERSION} fi -if [ "arm64" == ${SYS_ARCH} ];then +if [ "arm64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-debian${SYS_NAME}-arm64-${TOOL_VERSION} fi diff --git a/plugins/mongodb/versions/5.0/opensuse.sh b/plugins/mongodb/versions/5.0/opensuse.sh index 6b31cef7d..cd95a8682 100644 --- a/plugins/mongodb/versions/5.0/opensuse.sh +++ b/plugins/mongodb/versions/5.0/opensuse.sh @@ -50,7 +50,7 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${FILE_NAME} #--------------- mongosh tool install ------------------ # TOOL_VERSION=2.2.5 TOOL_FILE_NAME=mongosh-${TOOL_VERSION}-linux-x64 -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongosh-${TOOL_VERSION}-linux-arm64 fi TOOL_FILE_NAME_TGZ=${TOOL_FILE_NAME}.tgz @@ -70,11 +70,11 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${TOOL_FILE_NAME} #--------------- mongodb database install ------------------ # TOOL_VERSION=100.9.4 TOOL_FILE_NAME=mongodb-database-tools-suse${SYS_NAME}-x86_64-${TOOL_VERSION} -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-suse${SYS_NAME}-arm64-${TOOL_VERSION} fi -if [ "arm64" == ${SYS_ARCH} ];then +if [ "arm64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-suse${SYS_NAME}-arm64-${TOOL_VERSION} fi diff --git a/plugins/mongodb/versions/7.0/centos.sh b/plugins/mongodb/versions/7.0/centos.sh index c1c204408..20d766944 100644 --- a/plugins/mongodb/versions/7.0/centos.sh +++ b/plugins/mongodb/versions/7.0/centos.sh @@ -63,7 +63,7 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${FILE_NAME} #--------------- mongosh tool install ------------------ # TOOL_VERSION=2.2.5 TOOL_FILE_NAME=mongosh-${TOOL_VERSION}-linux-x64 -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongosh-${TOOL_VERSION}-linux-arm64 fi TOOL_FILE_NAME_TGZ=${TOOL_FILE_NAME}.tgz @@ -85,11 +85,11 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${TOOL_FILE_NAME} #--------------- mongodb database install ------------------ # TOOL_VERSION=100.9.4 TOOL_FILE_NAME=mongodb-database-tools-rhel${SYS_NAME}-x86_64-${TOOL_VERSION} -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-rhel${SYS_NAME}-aarch64-${TOOL_VERSION} fi -if [ "arm64" == ${SYS_ARCH} ];then +if [ "arm64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-rhel${SYS_NAME}-arm64-${TOOL_VERSION} fi diff --git a/plugins/mongodb/versions/7.0/euler.sh b/plugins/mongodb/versions/7.0/euler.sh index c1c204408..20d766944 100644 --- a/plugins/mongodb/versions/7.0/euler.sh +++ b/plugins/mongodb/versions/7.0/euler.sh @@ -63,7 +63,7 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${FILE_NAME} #--------------- mongosh tool install ------------------ # TOOL_VERSION=2.2.5 TOOL_FILE_NAME=mongosh-${TOOL_VERSION}-linux-x64 -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongosh-${TOOL_VERSION}-linux-arm64 fi TOOL_FILE_NAME_TGZ=${TOOL_FILE_NAME}.tgz @@ -85,11 +85,11 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${TOOL_FILE_NAME} #--------------- mongodb database install ------------------ # TOOL_VERSION=100.9.4 TOOL_FILE_NAME=mongodb-database-tools-rhel${SYS_NAME}-x86_64-${TOOL_VERSION} -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-rhel${SYS_NAME}-aarch64-${TOOL_VERSION} fi -if [ "arm64" == ${SYS_ARCH} ];then +if [ "arm64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-rhel${SYS_NAME}-arm64-${TOOL_VERSION} fi diff --git a/plugins/mongodb/versions/8.0/debian.sh b/plugins/mongodb/versions/8.0/debian.sh index ab761f0c0..99e34a5c5 100644 --- a/plugins/mongodb/versions/8.0/debian.sh +++ b/plugins/mongodb/versions/8.0/debian.sh @@ -42,7 +42,7 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${FILE_NAME} #--------------- mongosh tool install ------------------ # TOOL_VERSION=2.2.5 TOOL_FILE_NAME=mongosh-${TOOL_VERSION}-linux-x64 -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongosh-${TOOL_VERSION}-linux-arm64 fi TOOL_FILE_NAME_TGZ=${TOOL_FILE_NAME}.tgz @@ -62,11 +62,11 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${TOOL_FILE_NAME} #--------------- mongodb database install ------------------ # TOOL_VERSION=100.9.4 TOOL_FILE_NAME=mongodb-database-tools-debian${SYS_NAME}-x86_64-${TOOL_VERSION} -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-debian${SYS_NAME}-arm64-${TOOL_VERSION} fi -if [ "arm64" == ${SYS_ARCH} ];then +if [ "arm64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-debian${SYS_NAME}-arm64-${TOOL_VERSION} fi diff --git a/plugins/mongodb/versions/8.0/ubuntu.sh b/plugins/mongodb/versions/8.0/ubuntu.sh index 4db7a8745..0ee20e4e8 100644 --- a/plugins/mongodb/versions/8.0/ubuntu.sh +++ b/plugins/mongodb/versions/8.0/ubuntu.sh @@ -23,11 +23,11 @@ if [ "$SYS_NAME" -lt "2004" ];then SYS_NAME="2004" fi -if [ "$SYS_NAME" == "2204" ];then +if [ "$SYS_NAME" = "2204" ];then SYS_NAME="2204" fi -if [ "$SYS_NAME" == "2404" ];then +if [ "$SYS_NAME" = "2404" ];then SYS_NAME="2404" fi @@ -78,11 +78,11 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${TOOL_FILE_NAME} TOOL_VERSION=100.9.4 SYS_NAME=2204 TOOL_FILE_NAME=mongodb-database-tools-ubuntu${SYS_NAME}-x86_64-${TOOL_VERSION} -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-ubuntu${SYS_NAME}-arm64-${TOOL_VERSION} fi -if [ "arm64" == ${SYS_ARCH} ];then +if [ "arm64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-ubuntu${SYS_NAME}-arm64-${TOOL_VERSION} fi diff --git a/plugins/mongodb/versions/8.2/ubuntu.sh b/plugins/mongodb/versions/8.2/ubuntu.sh index f1eca4ace..3448497d2 100644 --- a/plugins/mongodb/versions/8.2/ubuntu.sh +++ b/plugins/mongodb/versions/8.2/ubuntu.sh @@ -57,7 +57,7 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${FILE_NAME} #--------------- mongosh tool install ------------------ # TOOL_VERSION=2.2.5 TOOL_FILE_NAME=mongosh-${TOOL_VERSION}-linux-x64 -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongosh-${TOOL_VERSION}-linux-arm64 fi TOOL_FILE_NAME_TGZ=${TOOL_FILE_NAME}.tgz @@ -78,11 +78,11 @@ cd ${MG_DIR} && rm -rf ${MG_DIR}/${TOOL_FILE_NAME} TOOL_VERSION=100.9.4 SYS_NAME=2204 TOOL_FILE_NAME=mongodb-database-tools-ubuntu${SYS_NAME}-x86_64-${TOOL_VERSION} -if [ "aarch64" == ${SYS_ARCH} ];then +if [ "aarch64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-ubuntu${SYS_NAME}-arm64-${TOOL_VERSION} fi -if [ "arm64" == ${SYS_ARCH} ];then +if [ "arm64" = ${SYS_ARCH} ];then TOOL_FILE_NAME=mongodb-database-tools-ubuntu${SYS_NAME}-arm64-${TOOL_VERSION} fi diff --git a/plugins/mysql-community/versions/8.3/install_generic.sh b/plugins/mysql-community/versions/8.3/install_generic.sh index 67debcca4..d7c8154d6 100755 --- a/plugins/mysql-community/versions/8.3/install_generic.sh +++ b/plugins/mysql-community/versions/8.3/install_generic.sh @@ -55,7 +55,7 @@ Install_mysql() { echo '正在安装脚本文件...' COMMUNITY_INSTALL - if [ "$?" == "0" ];then + if [ "$?" = "0" ];then mkdir -p $serverPath/mysql-community echo '8.3' > $serverPath/mysql-community/version.pl echo '安装完成' @@ -74,7 +74,7 @@ Uninstall_mysql() } action=$1 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_mysql else Uninstall_mysql diff --git a/plugins/nezha/install.sh b/plugins/nezha/install.sh index 17db0d06b..fdb76e7e6 100755 --- a/plugins/nezha/install.sh +++ b/plugins/nezha/install.sh @@ -20,7 +20,7 @@ serverPath=$(dirname "$rootPath") action=$1 type=$2 -if [ "${2}" == "" ];then +if [ "${2}" = "" ];then echo '缺少安装脚本...' exit 0 fi diff --git a/plugins/nezha/versions/2.2.5/install.sh b/plugins/nezha/versions/2.2.5/install.sh index cbb976dac..f295d9de4 100755 --- a/plugins/nezha/versions/2.2.5/install.sh +++ b/plugins/nezha/versions/2.2.5/install.sh @@ -172,7 +172,7 @@ Uninstall_App() } action=$1 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_App else Uninstall_App diff --git a/plugins/ollama/install.sh b/plugins/ollama/install.sh index 9049cd2d1..52ca9a7b0 100755 --- a/plugins/ollama/install.sh +++ b/plugins/ollama/install.sh @@ -12,7 +12,7 @@ serverPath=$(dirname "$rootPath") action=$1 type=$2 -if [ "${2}" == "" ];then +if [ "${2}" = "" ];then echo '缺少安装脚本...' exit 0 fi @@ -24,7 +24,7 @@ fi sh -x $curPath/versions/$2/install.sh $1 -if [ "${action}" == "uninstall" ];then +if [ "${action}" = "uninstall" ];then if [ -f /usr/lib/systemd/system/ollama.service ] || [ -f /lib/systemd/system/ollama.service ] ;then systemctl stop ollama systemctl disable ollama diff --git a/plugins/openresty/install.sh b/plugins/openresty/install.sh index 9b6e79ffe..9f4b0f1f2 100755 --- a/plugins/openresty/install.sh +++ b/plugins/openresty/install.sh @@ -39,7 +39,7 @@ else useradd -g www -s /bin/bash www fi -if [ "${action}" == "upgrade" ];then +if [ "${action}" = "upgrade" ];then sh -x $curPath/versions/$2/install.sh $1 echo "${VERSION}" > $serverPath/openresty/version.pl @@ -54,12 +54,12 @@ if [ "${action}" == "upgrade" ];then fi -if [ "${2}" == "" ];then +if [ "${2}" = "" ];then echo '缺少安装脚本版本...' exit 0 fi -if [ "${action}" == "uninstall" ];then +if [ "${action}" = "uninstall" ];then if [ -f /usr/lib/systemd/system/openresty.service ] || [ -f /lib/systemd/system/openresty.service ];then systemctl stop openresty rm -rf /usr/systemd/system/openresty.service @@ -76,7 +76,7 @@ fi sh -x $curPath/versions/$2/install.sh $1 -if [ "${action}" == "install" ] && [ -d $serverPath/openresty ];then +if [ "${action}" = "install" ] && [ -d $serverPath/openresty ];then echo "${VERSION}" > $serverPath/openresty/version.pl mkdir -p $serverPath/web_conf/php/conf diff --git a/plugins/openresty/versions/1.19.3/install.sh b/plugins/openresty/versions/1.19.3/install.sh index c12223f96..fda3d7726 100644 --- a/plugins/openresty/versions/1.19.3/install.sh +++ b/plugins/openresty/versions/1.19.3/install.sh @@ -19,7 +19,7 @@ openrestyDir=${serverPath}/source/openresty Install_openresty() { - if [ "${action}" == "install" ];then + if [ "${action}" = "install" ];then if [ -d $serverPath/openresty ];then exit 0 fi @@ -145,7 +145,7 @@ Install_openresty() cd ${openrestyDir} && wget -O $openrestyDir/zstd-nginx-module.tar.gz https://github.com/tokers/zstd-nginx-module/archive/refs/heads/master.tar.gz cd ${openrestyDir} && tar -zxvf zstd-nginx-module.tar.gz - if [ "$sysName" == "Darwin" ];then + if [ "$sysName" = "Darwin" ];then export ZSTD_INC=/opt/homebrew/include export ZSTD_LIB=/opt/homebrew/lib fi @@ -203,9 +203,9 @@ Uninstall_openresty() } action=$1 -if [ "${1}" == "install" ];then +if [ "${1}" = "install" ];then Install_openresty -elif [ "${1}" == "upgrade" ];then +elif [ "${1}" = "upgrade" ];then Install_openresty else Uninstall_openresty diff --git a/plugins/openresty/versions/1.31.1/install.sh b/plugins/openresty/versions/1.31.1/install.sh index 9ee3e57e2..520b46490 100644 --- a/plugins/openresty/versions/1.31.1/install.sh +++ b/plugins/openresty/versions/1.31.1/install.sh @@ -20,7 +20,7 @@ openrestyDir=${serverPath}/source/openresty Install_openresty() { - if [ "${action}" == "install" ];then + if [ "${action}" = "install" ];then if [ -d $serverPath/openresty ];then exit 0 fi @@ -77,7 +77,7 @@ Install_openresty() opensslVersion="3.5.5" libresslVersion="3.9.1" pcreVersion='8.45' - if [ "$sysName" == "Darwin" ];then + if [ "$sysName" = "Darwin" ];then if [ ! -f ${openrestyDir}/pcre-${pcreVersion}.tar.gz ];then wget --no-check-certificate -O ${openrestyDir}/pcre-${pcreVersion}.tar.gz https://netix.dl.sourceforge.net/project/pcre/pcre/${pcreVersion}/pcre-${pcreVersion}.tar.gz @@ -219,9 +219,9 @@ Uninstall_openresty() } action=$1 -if [ "${1}" == "install" ];then +if [ "${1}" = "install" ];then Install_openresty -elif [ "${1}" == "upgrade" ];then +elif [ "${1}" = "upgrade" ];then Install_openresty else Uninstall_openresty diff --git a/plugins/php-apt/install.sh b/plugins/php-apt/install.sh index ac4eefb2b..15077dd32 100755 --- a/plugins/php-apt/install.sh +++ b/plugins/php-apt/install.sh @@ -19,7 +19,7 @@ else fi _os=`uname` -if [ ${_os} == "Darwin" ]; then +if [ ${_os} = "Darwin" ]; then OSNAME='macos' elif grep -Eqi "Debian" /etc/issue || grep -Eq "Debian" /etc/*-release; then OSNAME='debian' @@ -33,7 +33,7 @@ action=$1 type=$2 apt_ver=${type:0:1}.${type:1:2} -if [ "${2}" == "" ];then +if [ "${2}" = "" ];then echo '缺少安装脚本...' exit 0 fi diff --git a/plugins/php-apt/versions/84/install.sh b/plugins/php-apt/versions/84/install.sh index 435102c7a..26c13de94 100755 --- a/plugins/php-apt/versions/84/install.sh +++ b/plugins/php-apt/versions/84/install.sh @@ -23,7 +23,7 @@ Install_php() { #------------------------ install start ------------------------------------# apt -y install php${version} php${version}-fpm php${version}-dev -if [ "$?" == "0" ];then +if [ "$?" = "0" ];then mkdir -p $serverPath/php-apt/${PHP_VER} fi @@ -40,7 +40,7 @@ echo "卸载php-${version}..." } action=${1} -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_php else Uninstall_php diff --git a/plugins/php-apt/versions/common/brotli.sh b/plugins/php-apt/versions/common/brotli.sh index 89769c8e4..231b40c73 100755 --- a/plugins/php-apt/versions/common/brotli.sh +++ b/plugins/php-apt/versions/common/brotli.sh @@ -20,7 +20,7 @@ LIBV=0.18.3 extVer=`bash $curPath/lib.sh $version` extFile=/usr/lib/php/${extVer}/${LIBNAME}.so -if [ "$sysName" == "Darwin" ];then +if [ "$sysName" = "Darwin" ];then BAK='_bak' else BAK='' @@ -87,8 +87,8 @@ Uninstall_lib() } -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php-apt/versions/common/sg11.sh b/plugins/php-apt/versions/common/sg11.sh index 7577163a5..9b7fb65df 100644 --- a/plugins/php-apt/versions/common/sg11.sh +++ b/plugins/php-apt/versions/common/sg11.sh @@ -77,7 +77,7 @@ Install_lib() exit fi - if [ "$OSNAME" == 'macos' ];then + if [ "$OSNAME" = 'macos' ];then xattr -c * $extFile fi fi diff --git a/plugins/php-apt/versions/common/swoole.sh b/plugins/php-apt/versions/common/swoole.sh index 1a016bda8..549a8f29a 100755 --- a/plugins/php-apt/versions/common/swoole.sh +++ b/plugins/php-apt/versions/common/swoole.sh @@ -22,21 +22,21 @@ APT_INSTALL=0 if [ `echo "$version < 7.0"|bc` -eq 1 ];then LIBV=1.10.1 -elif [ "$version" == "7.1" ];then +elif [ "$version" = "7.1" ];then LIBV=4.5.2 -elif [ "$version" == "7.0" ];then +elif [ "$version" = "7.0" ];then LIBV=4.3.0 elif [ `echo "$version < 8.0"|bc` -eq 1 ];then LIBV=6.0.2 -elif [ "$version" == "8.1" ];then +elif [ "$version" = "8.1" ];then LIBV=6.1.7 -elif [ "$version" == "8.2" ];then +elif [ "$version" = "8.2" ];then LIBV=6.2.0 -elif [ "$version" == "8.3" ];then +elif [ "$version" = "8.3" ];then LIBV=6.2.0 -elif [ "$version" == "8.4" ];then +elif [ "$version" = "8.4" ];then LIBV=6.2.0 -elif [ "$version" == "8.5" ];then +elif [ "$version" = "8.5" ];then LIBV=6.2.0 else echo 'ok' @@ -45,10 +45,10 @@ fi # to Apt -if [ "$APT_INSTALL" == "1" ];then - if [ "$actionType" == 'install' ];then +if [ "$APT_INSTALL" = "1" ];then + if [ "$actionType" = 'install' ];then apt install -y php${version}-${LIBNAME} - elif [ "$actionType" == 'uninstall' ];then + elif [ "$actionType" = 'uninstall' ];then apt remove -y php${version}-${LIBNAME} fi exit 0 @@ -60,7 +60,7 @@ extFile=/usr/lib/php/${extVer}/${LIBNAME}.so -if [ "$sysName" == "Darwin" ];then +if [ "$sysName" = "Darwin" ];then BAK='_bak' else BAK='' @@ -127,8 +127,8 @@ Uninstall_lib() } -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php-apt/versions/lib.sh b/plugins/php-apt/versions/lib.sh index 27114a858..205f4c0e4 100644 --- a/plugins/php-apt/versions/lib.sh +++ b/plugins/php-apt/versions/lib.sh @@ -10,28 +10,28 @@ serverPath=$(dirname "$rootPath") version=$1 -if [ "$version" == '5.6' ];then +if [ "$version" = '5.6' ];then echo '20131226' -elif [[ "$version" == '7.0' ]]; then +elif [[ "$version" = '7.0' ]]; then echo '20151012' -elif [[ "$version" == '7.1' ]]; then +elif [[ "$version" = '7.1' ]]; then echo '20160303' -elif [[ "$version" == '7.2' ]]; then +elif [[ "$version" = '7.2' ]]; then echo '20170718' -elif [[ "$version" == '7.3' ]]; then +elif [[ "$version" = '7.3' ]]; then echo '20180731' -elif [[ "$version" == '7.4' ]]; then +elif [[ "$version" = '7.4' ]]; then echo '20190902' -elif [[ "$version" == '8.0' ]]; then +elif [[ "$version" = '8.0' ]]; then echo '20200930' -elif [[ "$version" == '8.1' ]]; then +elif [[ "$version" = '8.1' ]]; then echo '20210902' -elif [[ "$version" == '8.2' ]]; then +elif [[ "$version" = '8.2' ]]; then echo '20220829' -elif [[ "$version" == '8.3' ]]; then +elif [[ "$version" = '8.3' ]]; then echo '20230831' -elif [[ "$version" == '8.4' ]]; then +elif [[ "$version" = '8.4' ]]; then echo '20240924' -elif [[ "$version" == '8.5' ]]; then +elif [[ "$version" = '8.5' ]]; then echo '20250925' fi \ No newline at end of file diff --git a/plugins/php-yum/versions/80/install.sh b/plugins/php-yum/versions/80/install.sh index 070c2544c..67dc69be7 100755 --- a/plugins/php-yum/versions/80/install.sh +++ b/plugins/php-yum/versions/80/install.sh @@ -19,7 +19,7 @@ Install_php() yum install -y php80 php80-php-fpm -if [ "$?" == "0" ];then +if [ "$?" = "0" ];then mkdir -p $serverPath/php-yum/${PHP_VER} fi @@ -34,7 +34,7 @@ Uninstall_php() } action=${1} -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_php else Uninstall_php diff --git a/plugins/php-yum/versions/84/install.sh b/plugins/php-yum/versions/84/install.sh index 105495362..8541e2d9d 100755 --- a/plugins/php-yum/versions/84/install.sh +++ b/plugins/php-yum/versions/84/install.sh @@ -17,7 +17,7 @@ Install_php() { #------------------------ install start ------------------------------------# yum install -y php84 php84-php-fpm -if [ "$?" == "0" ];then +if [ "$?" = "0" ];then mkdir -p $serverPath/php-yum/${PHP_VER} fi @@ -32,7 +32,7 @@ Uninstall_php() } action=${1} -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_php else Uninstall_php diff --git a/plugins/php-yum/versions/common.sh b/plugins/php-yum/versions/common.sh index e4786a448..5fa6fa5e1 100644 --- a/plugins/php-yum/versions/common.sh +++ b/plugins/php-yum/versions/common.sh @@ -35,7 +35,7 @@ if [ "$action" = 'install' ];then yum install -y php${version}-php-pecl-${extName} fi - # if [ "${extName}" == "mysql" ];then + # if [ "${extName}" = "mysql" ];then # yum install -y php74-php-pecl-mysql # fi fi diff --git a/plugins/php-yum/versions/common/bak_brotli.sh b/plugins/php-yum/versions/common/bak_brotli.sh index a23a344b0..4de92f693 100755 --- a/plugins/php-yum/versions/common/bak_brotli.sh +++ b/plugins/php-yum/versions/common/bak_brotli.sh @@ -82,8 +82,8 @@ Uninstall_lib() } -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php-yum/versions/common/ioncube.sh b/plugins/php-yum/versions/common/ioncube.sh index 90ba45f47..fcdc1ffae 100755 --- a/plugins/php-yum/versions/common/ioncube.sh +++ b/plugins/php-yum/versions/common/ioncube.sh @@ -32,7 +32,7 @@ extIni=${cfgDir}/10-${LIBNAME}.ini echo $extSoFile echo $extIni -if [ "$sysName" == "Darwin" ];then +if [ "$sysName" = "Darwin" ];then BAK='_bak' else BAK='' diff --git a/plugins/php-yum/versions/common/opcache.sh b/plugins/php-yum/versions/common/opcache.sh index 873253b79..fa42ed394 100755 --- a/plugins/php-yum/versions/common/opcache.sh +++ b/plugins/php-yum/versions/common/opcache.sh @@ -27,7 +27,7 @@ ext_file=${ext_dir}/10-opcache.ini echo $ext_file -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then yum install -y php${version}-php-${LIBNAME} echo "ls ${cfgDir}/php${version}/php.d | grep "${LIBNAME}.ini"| cut -d \ -f 1" find_opcache=`ls ${cfgDir}/php${version}/php.d | grep "${LIBNAME}.ini"| cut -d \ -f 1` diff --git a/plugins/php/lib/openssl_10.sh b/plugins/php/lib/openssl_10.sh index d369d4f25..fdb536f93 100644 --- a/plugins/php/lib/openssl_10.sh +++ b/plugins/php/lib/openssl_10.sh @@ -25,7 +25,7 @@ fi if [ ! -d ${SERVER_ROOT}/openssl10 ];then cd ${SOURCE_ROOT} - if [ "$LOCAL_ADDR" == 'cn' ];then + if [ "$LOCAL_ADDR" -eq 'cn' ];then if [ ! -f ${SOURCE_ROOT}/openssl-${opensslVersion}.tar.gz ];then wget --no-check-certificate -O openssl-${opensslVersion}.tar.gz https://dl.midoks.icu/lib/openssl-${opensslVersion}.tar.gz -T 20 fi diff --git a/plugins/php/versions/52/install.sh b/plugins/php/versions/52/install.sh index caee453a0..b32a7dca7 100755 --- a/plugins/php/versions/52/install.sh +++ b/plugins/php/versions/52/install.sh @@ -83,16 +83,16 @@ if [ -f $serverPath/php/${PHP_VER}/bin/php ];then fi OPTIONS='--without-iconv' -if [ $sysName == 'Darwin' ]; then +if [ $sysName = 'Darwin' ]; then OPTIONS="${OPTIONS} --with-freetype-dir=${serverPath}/lib/freetype" fi IS_64BIT=`getconf LONG_BIT` -if [ "$IS_64BIT" == "64" ];then +if [ "$IS_64BIT" = "64" ];then OPTIONS="${OPTIONS} --with-libdir=lib64" fi -if [ "${SYS_ARCH}" == "aarch64" ];then +if [ "${SYS_ARCH}" = "aarch64" ];then OPTIONS="$OPTIONS --build=aarch64-unknown-linux-gnu --host=aarch64-unknown-linux-gnu" fi @@ -156,7 +156,7 @@ Uninstall_php() } action=${1} -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_php else Uninstall_php diff --git a/plugins/php/versions/53/eaccelerator.sh b/plugins/php/versions/53/eaccelerator.sh index 027e70147..9acfb920b 100755 --- a/plugins/php/versions/53/eaccelerator.sh +++ b/plugins/php/versions/53/eaccelerator.sh @@ -24,7 +24,7 @@ version=$2 NON_ZTS_FILENAME=`ls $serverPath/php/${version}/lib/php/extensions | grep no-debug-non-zts` extFile=$serverPath/php/${version}/lib/php/extensions/${NON_ZTS_FILENAME}/${LIBNAME}.so -if [ "$sysName" == "Darwin" ];then +if [ "$sysName" = "Darwin" ];then BAK='_bak' else BAK='' @@ -102,8 +102,8 @@ Uninstall_lib() } -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php/versions/74/install.sh b/plugins/php/versions/74/install.sh index f11be5134..eafa94099 100755 --- a/plugins/php/versions/74/install.sh +++ b/plugins/php/versions/74/install.sh @@ -37,11 +37,11 @@ if [ ! -d $sourcePath/php/php${PHP_VER} ];then # 中国优化安装 cn=$(curl -fsSL -m 10 -s http://ipinfo.io/json | grep "\"country\": \"CN\"") LOCAL_ADDR=common - if [ ! -z "$cn" ] || [ "$?" == "0" ] ;then + if [ ! -z "$cn" ] || [ "$?" = "0" ] ;then LOCAL_ADDR=cn fi - if [ "$LOCAL_ADDR" == "cn" ];then + if [ "$LOCAL_ADDR" = "cn" ];then if [ ! -f $sourcePath/php/php-${version}.tar.xz ];then wget --no-check-certificate -O $sourcePath/php/php-${version}.tar.xz https://mirrors.nju.edu.cn/php/php-${version}.tar.xz fi @@ -74,12 +74,12 @@ fi cd $sourcePath/php/php${PHP_VER} OPTIONS='--without-iconv' -# if [ $sysName == 'Darwin' ]; then +# if [ $sysName = 'Darwin' ]; then # OPTIONS="${OPTIONS} --with-external-pcre=$(brew --prefix pcre2)" # fi IS_64BIT=`getconf LONG_BIT` -if [ "$IS_64BIT" == "64" ];then +if [ "$IS_64BIT" = "64" ];then OPTIONS="${OPTIONS} --with-libdir=lib64" fi @@ -163,7 +163,7 @@ Uninstall_php() } action=${1} -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_php else Uninstall_php diff --git a/plugins/php/versions/common/curl.sh b/plugins/php/versions/common/curl.sh index 609974209..5a9e189e4 100755 --- a/plugins/php/versions/common/curl.sh +++ b/plugins/php/versions/common/curl.sh @@ -116,8 +116,8 @@ Uninstall_lib() -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php/versions/common/event.sh b/plugins/php/versions/common/event.sh index 711b7746f..459576e29 100644 --- a/plugins/php/versions/common/event.sh +++ b/plugins/php/versions/common/event.sh @@ -36,7 +36,7 @@ NON_ZTS_FILENAME=`ls $serverPath/php/${version}/${LIB_PATH_NAME}/extensions | gr extFile=$serverPath/php/${version}/${LIB_PATH_NAME}/extensions/${NON_ZTS_FILENAME}/${LIBNAME}.so sysName=`uname` -if [ "$sysName" == "Darwin" ];then +if [ "$sysName" = "Darwin" ];then BAK='_bak' else BAK='' @@ -115,8 +115,8 @@ Uninstall_lib() } -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php/versions/common/gmp.sh b/plugins/php/versions/common/gmp.sh index 48b168905..279a47969 100755 --- a/plugins/php/versions/common/gmp.sh +++ b/plugins/php/versions/common/gmp.sh @@ -19,7 +19,7 @@ version=$2 LIBNAME=gmp LIBV=0 -if [ "$version" == "53" ];then +if [ "$version" = "53" ];then echo "i wont support it" exit fi @@ -115,8 +115,8 @@ Uninstall_lib() -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php/versions/common/mongodb.sh b/plugins/php/versions/common/mongodb.sh index 96228c86b..11103cf81 100755 --- a/plugins/php/versions/common/mongodb.sh +++ b/plugins/php/versions/common/mongodb.sh @@ -21,19 +21,19 @@ if [ "$version" -ge '74' ];then LIBV=1.20.0 fi -if [ "$version" == '71' ];then +if [ "$version" = '71' ];then LIBV=1.11.1 fi -if [ "$version" == '70' ];then +if [ "$version" = '70' ];then LIBV=1.7.5 fi -if [ "$version" == '56' ];then +if [ "$version" = '56' ];then LIBV=1.7.4 fi -if [ "$version" == '55' ];then +if [ "$version" = '55' ];then LIBV=1.5.3 fi @@ -122,8 +122,8 @@ Uninstall_lib() } -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php/versions/common/pcntl.sh b/plugins/php/versions/common/pcntl.sh index 8e01f8a0e..3e460c516 100755 --- a/plugins/php/versions/common/pcntl.sh +++ b/plugins/php/versions/common/pcntl.sh @@ -26,7 +26,7 @@ NON_ZTS_FILENAME=`ls $serverPath/php/${version}/${LIB_PATH_NAME}/extensions | gr extFile=$serverPath/php/${version}/${LIB_PATH_NAME}/extensions/${NON_ZTS_FILENAME}/${LIBNAME}.so sysName=`uname` -if [ "$sysName" == "Darwin" ];then +if [ "$sysName" = "Darwin" ];then BAK='_bak' else BAK='' @@ -103,8 +103,8 @@ Uninstall_lib() -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php/versions/common/phalcon.sh b/plugins/php/versions/common/phalcon.sh index b80ddde9f..3675c10a8 100755 --- a/plugins/php/versions/common/phalcon.sh +++ b/plugins/php/versions/common/phalcon.sh @@ -35,7 +35,7 @@ NON_ZTS_FILENAME=`ls $serverPath/php/${version}/${LIB_PATH_NAME}/extensions | gr extFile=$serverPath/php/${version}/${LIB_PATH_NAME}/extensions/${NON_ZTS_FILENAME}/${LIBNAME}.so sysName=`uname` -if [ "$sysName" == "Darwin" ];then +if [ "$sysName" = "Darwin" ];then BAK='_bak' else BAK='' @@ -63,7 +63,7 @@ Install_lib() cd $php_lib/${LIBNAME}-${LIBV} OPTIONS='' - if [ "${SYS_ARCH}" == "aarch64" ] && [ "$version" -lt "56" ];then + if [ "${SYS_ARCH}" = "aarch64" ] && [ "$version" -lt "56" ];then OPTIONS="$OPTIONS --build=aarch64-unknown-linux-gnu --host=aarch64-unknown-linux-gnu" fi @@ -122,8 +122,8 @@ Uninstall_lib() -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php/versions/common/readline.sh b/plugins/php/versions/common/readline.sh index 71c13ad56..c4015eed7 100755 --- a/plugins/php/versions/common/readline.sh +++ b/plugins/php/versions/common/readline.sh @@ -35,7 +35,7 @@ NON_ZTS_FILENAME=`ls $serverPath/php/${version}/${LIB_PATH_NAME}/extensions | gr extFile=$serverPath/php/${version}/${LIB_PATH_NAME}/extensions/${NON_ZTS_FILENAME}/${LIBNAME}.so sysName=`uname` -if [ "$sysName" == "Darwin" ];then +if [ "$sysName" = "Darwin" ];then BAK='_bak' else BAK='' @@ -62,7 +62,7 @@ Install_lib() fi OPTIONS="" - if [ "${SYS_ARCH}" == "aarch64" ] && [ "$version" -lt "56" ];then + if [ "${SYS_ARCH}" = "aarch64" ] && [ "$version" -lt "56" ];then OPTIONS="$OPTIONS --build=aarch64-unknown-linux-gnu --host=aarch64-unknown-linux-gnu" fi @@ -115,8 +115,8 @@ Uninstall_lib() -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php/versions/common/sg11.sh b/plugins/php/versions/common/sg11.sh index 8bcf13f33..263319742 100644 --- a/plugins/php/versions/common/sg11.sh +++ b/plugins/php/versions/common/sg11.sh @@ -30,7 +30,7 @@ fi NON_ZTS_FILENAME=`ls $serverPath/php/${version}/${LIB_PATH_NAME}/extensions | grep no-debug-non-zts` extFile=$serverPath/php/${version}/${LIB_PATH_NAME}/extensions/${NON_ZTS_FILENAME}/${LIBNAME}.so -if [ "$sysName" == "Darwin" ];then +if [ "$sysName" = "Darwin" ];then BAK='_bak' else BAK='' @@ -41,7 +41,7 @@ Install_lib() { bash ${rootPath}/scripts/getos.sh OSNAME=`cat ${rootPath}/data/osname.pl` - if [ "$OSNAME" == 'macos' ];then + if [ "$OSNAME" = 'macos' ];then VERSION_ID=none else VERSION_ID=`cat /etc/*-release | grep VERSION_ID | awk -F = '{print $2}' | awk -F "\"" '{print $2}'` @@ -51,7 +51,7 @@ Install_lib() DEFAULT_OSNAME=linux-x86_64 SUFFIX_NAME=lin - if [ "$OSNAME" == 'macos' ];then + if [ "$OSNAME" = 'macos' ];then DEFAULT_OSNAME=macosx SUFFIX_NAME=dar fi @@ -131,8 +131,8 @@ Uninstall_lib() } -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php/versions/common/swoole.sh b/plugins/php/versions/common/swoole.sh index 452aff91a..c284423bd 100755 --- a/plugins/php/versions/common/swoole.sh +++ b/plugins/php/versions/common/swoole.sh @@ -19,23 +19,23 @@ LIBV=5.1.6 if [ "$version" -lt "70" ];then LIBV=1.10.1 -elif [ "$version" == "70" ];then +elif [ "$version" = "70" ];then LIBV=4.3.0 -elif [ "$version" == "71" ];then +elif [ "$version" = "71" ];then LIBV=4.5.2 elif [ "$version" -le "74" ];then LIBV=4.8.10 elif [ "$version" -lt "80" ];then LIBV=6.0.2 -elif [ "$version" == "81" ];then +elif [ "$version" = "81" ];then LIBV=6.1.7 -elif [ "$version" == "82" ];then +elif [ "$version" = "82" ];then LIBV=6.2.0 -elif [ "$version" == "83" ];then +elif [ "$version" = "83" ];then LIBV=6.2.0 -elif [ "$version" == "84" ];then +elif [ "$version" = "84" ];then LIBV=6.2.0 -elif [ "$version" == "85" ];then +elif [ "$version" = "85" ];then LIBV=6.2.0 else echo 'other?' @@ -51,7 +51,7 @@ NON_ZTS_FILENAME=`ls $serverPath/php/${version}/${LIB_PATH_NAME}/extensions | gr extFile=$serverPath/php/${version}/${LIB_PATH_NAME}/extensions/${NON_ZTS_FILENAME}/${LIBNAME}.so sysName=`uname` -if [ "$sysName" == "Darwin" ];then +if [ "$sysName" = "Darwin" ];then BAK='_bak' else BAK='' @@ -144,8 +144,8 @@ Uninstall_lib() -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php/versions/common/yaml.sh b/plugins/php/versions/common/yaml.sh index 9c58704a5..5a1d9dc51 100755 --- a/plugins/php/versions/common/yaml.sh +++ b/plugins/php/versions/common/yaml.sh @@ -110,8 +110,8 @@ Uninstall_lib() } -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/php/versions/common/zip.sh b/plugins/php/versions/common/zip.sh index 1c4021502..7511a38cd 100755 --- a/plugins/php/versions/common/zip.sh +++ b/plugins/php/versions/common/zip.sh @@ -32,7 +32,7 @@ NON_ZTS_FILENAME=`ls $serverPath/php/${version}/${LIB_PATH_NAME}/extensions | gr extFile=$serverPath/php/${version}/${LIB_PATH_NAME}/extensions/${NON_ZTS_FILENAME}/${LIBNAME}.so sysName=`uname` -if [ "$sysName" == "Darwin" ];then +if [ "$sysName" = "Darwin" ];then BAK='_bak' else BAK='' @@ -120,8 +120,8 @@ Uninstall_lib() -if [ "$actionType" == 'install' ];then +if [ "$actionType" = 'install' ];then Install_lib -elif [ "$actionType" == 'uninstall' ];then +elif [ "$actionType" = 'uninstall' ];then Uninstall_lib fi \ No newline at end of file diff --git a/plugins/phpldapadmin/install.sh b/plugins/phpldapadmin/install.sh index e4a3566f1..08ce908f7 100755 --- a/plugins/phpldapadmin/install.sh +++ b/plugins/phpldapadmin/install.sh @@ -14,7 +14,7 @@ if [ -f ${rootPath}/bin/activate ];then . ${rootPath}/bin/activate fi -if [ "$sys_os" == "Darwin" ];then +if [ "$sys_os" = "Darwin" ];then BAK='_bak' else BAK='' @@ -23,7 +23,7 @@ fi sysName=`uname` echo "use system: ${sysName}" -if [ "${sysName}" == "Darwin" ]; then +if [ "${sysName}" = "Darwin" ]; then OSNAME='macos' elif grep -Eqi "CentOS" /etc/issue || grep -Eq "CentOS" /etc/*-release; then OSNAME='centos' @@ -83,7 +83,7 @@ Uninstall_App() } action=$1 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_App $2 else Uninstall_App $2 diff --git a/plugins/phpmyadmin/install.sh b/plugins/phpmyadmin/install.sh index 41f8a807c..1b53a6b4e 100755 --- a/plugins/phpmyadmin/install.sh +++ b/plugins/phpmyadmin/install.sh @@ -14,7 +14,7 @@ if [ -f ${rootPath}/bin/activate ];then . ${rootPath}/bin/activate fi -if [ "$sys_os" == "Darwin" ];then +if [ "$sys_os" = "Darwin" ];then BAK='_bak' else BAK='' @@ -23,7 +23,7 @@ fi sysName=`uname` echo "use system: ${sysName}" -if [ "${sysName}" == "Darwin" ]; then +if [ "${sysName}" = "Darwin" ]; then OSNAME='macos' elif grep -Eqi "CentOS" /etc/issue || grep -Eq "CentOS" /etc/*-release; then OSNAME='centos' @@ -82,7 +82,7 @@ Uninstall_phpmyadmin() } action=$1 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_phpmyadmin $2 else Uninstall_phpmyadmin $2 diff --git a/plugins/postgresql/versions/15/install.sh b/plugins/postgresql/versions/15/install.sh index 936de20ea..0571dbcf3 100755 --- a/plugins/postgresql/versions/15/install.sh +++ b/plugins/postgresql/versions/15/install.sh @@ -120,7 +120,7 @@ Uninstall_App() } action=$1 -if [ "${1}" == "install" ];then +if [ "${1}" = "install" ];then Install_App else Uninstall_App diff --git a/plugins/prometheus/versions/3.5.0/linux.sh b/plugins/prometheus/versions/3.5.0/linux.sh index 79fc102eb..efdf760e1 100644 --- a/plugins/prometheus/versions/3.5.0/linux.sh +++ b/plugins/prometheus/versions/3.5.0/linux.sh @@ -17,11 +17,11 @@ sysArch=`arch` sysName=`uname` ARCH_NAME=amd64 -if [ "$sysArch" == "arm64" ];then +if [ "$sysArch" = "arm64" ];then ARCH_NAME=arm64 -elif [ "$sysArch" == "x86_64" ]; then +elif [ "$sysArch" = "x86_64" ]; then ARCH_NAME=amd64 -elif [ "$sysArch" == "aarch64" ]; then +elif [ "$sysArch" = "aarch64" ]; then ARCH_NAME=aarch64 fi @@ -54,7 +54,7 @@ Uninstall_App() } action=${1} -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_App else Uninstall_App diff --git a/plugins/pureftp/install.sh b/plugins/pureftp/install.sh index 685c1ba30..9a28b4b44 100755 --- a/plugins/pureftp/install.sh +++ b/plugins/pureftp/install.sh @@ -16,7 +16,7 @@ fi sysName=`uname` echo "use system: ${sysName}" -if [ ${sysName} == "Darwin" ]; then +if [ ${sysName} = "Darwin" ]; then OSNAME='macos' elif grep -Eqi "CentOS" /etc/issue || grep -Eq "CentOS" /etc/*-release; then OSNAME='centos' @@ -66,7 +66,7 @@ Install_pureftp() md5_ok=451879495ba61c1d7dcfca8dd231119f if [ -f $serverPath/source/pureftp/pure-ftpd-${VER}.tar.gz ];then md5_check=`md5sum $serverPath/source/pureftp/pure-ftpd-${VER}.tar.gz | awk '{print $1}'` - if [ "${md5_ok}" == "${md5_check}" ]; then + if [ "${md5_ok}" = "${md5_check}" ]; then echo "pure-ftpd file check ok" fi fi @@ -131,7 +131,7 @@ Uninstall_pureftp() } action=$1 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_pureftp $2 else Uninstall_pureftp $2 diff --git a/plugins/redis/install.sh b/plugins/redis/install.sh index 681e88717..5535c5dc2 100755 --- a/plugins/redis/install.sh +++ b/plugins/redis/install.sh @@ -36,7 +36,7 @@ Install_App() cd $REDIS_DIR && tar -zxvf ${FILE_TGZ} CMD_MAKE=`which gmake` - if [ "$?" == "0" ];then + if [ "$?" = "0" ];then cd redis-${VERSION} && gmake PREFIX=$serverPath/redis install else cd redis-${VERSION} && make PREFIX=$serverPath/redis install @@ -89,7 +89,7 @@ Uninstall_App() } action=$1 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_App else Uninstall_App diff --git a/plugins/sphinx/install.sh b/plugins/sphinx/install.sh index 14ae70189..96d26caba 100755 --- a/plugins/sphinx/install.sh +++ b/plugins/sphinx/install.sh @@ -31,9 +31,9 @@ if [ -f ${rootPath}/data/osname.pl ];then OSNAME=`cat ${rootPath}/data/osname.pl` fi -if [ "${OSNAME}" == "centos" ] || - [ "${OSNAME}" == "fedora" ] || - [ "${OSNAME}" == "alma" ]; then +if [ "${OSNAME}" = "centos" ] || + [ "${OSNAME}" = "fedora" ] || + [ "${OSNAME}" = "alma" ]; then yum install -y postgresql-libs unixODBC fi diff --git a/plugins/tamper_proof_py/install.sh b/plugins/tamper_proof_py/install.sh index 145340496..5f30f62b4 100755 --- a/plugins/tamper_proof_py/install.sh +++ b/plugins/tamper_proof_py/install.sh @@ -51,7 +51,7 @@ Uninstall_App() } action=$1 -if [ "${1}" == 'install' ];then +if [ "${1}" = 'install' ];then Install_App else Uninstall_App diff --git a/plugins/webstats/install.old.sh b/plugins/webstats/install.old.sh index 606c3c055..40ca8c85d 100755 --- a/plugins/webstats/install.old.sh +++ b/plugins/webstats/install.old.sh @@ -86,14 +86,14 @@ Install_App() export PATH=$PATH:$serverPath/webstats/luarocks/bin if [ ! -f $serverPath/webstats/lua/lsqlite3.so ];then - if [ "${sys_os}" == "Darwin" ];then + if [ "${sys_os}" = "Darwin" ];then cd $serverPath/source/webstats/lsqlite3_fsl09y # SQLITE_DIR=/usr/local/Cellar/sqlite/3.36.0 BREW_DIR=`which brew` BREW_DIR=${BREW_DIR/\/bin\/brew/} echo "BREW_DIR:"${BREW_DIR} find_cfg=`cat Makefile | grep 'SQLITE_DIR'` - if [ "$find_cfg" == "" ];then + if [ "$find_cfg" = "" ];then LIB_SQLITE_DIR=`brew info sqlite | grep ${BREW_DIR}/Cellar/sqlite | cut -d \ -f 1 | awk 'END {print}'` echo "LIB_SQLITE_DIR:"${LIB_SQLITE_DIR} sed -i $BAK "s#\$(ROCKSPEC)#\$(ROCKSPEC) SQLITE_DIR=${LIB_SQLITE_DIR}#g" Makefile diff --git a/plugins/webstats/install.sh b/plugins/webstats/install.sh index 82abc6bff..5f770961c 100755 --- a/plugins/webstats/install.sh +++ b/plugins/webstats/install.sh @@ -18,7 +18,7 @@ sys_os=`uname` HTTP_PREFIX="https://" LOCAL_ADDR=common cn=$(curl -fsSL -m 10 -s http://ipinfo.io/json | grep "\"country\": \"CN\"") -if [ ! -z "$cn" ] || [ "$?" == "0" ] ;then +if [ ! -z "$cn" ] || [ "$?" = "0" ] ;then LOCAL_ADDR=cn HTTP_PREFIX="https://" fi @@ -92,7 +92,7 @@ Install_App() echo "BREW_DIR:"${BREW_DIR} LIB_SQLITE_DIR=/opt/homebrew/opt/sqlite find_cfg=`cat Makefile | grep 'SQLITE_DIR'` - if [ "$find_cfg" == "" ];then + if [ "$find_cfg" = "" ];then # LIB_SQLITE_DIR=`brew info sqlite | grep /opt/homebrew/opt/sqlite | cut -d \ -f 1 | awk 'END {print}'` echo "LIB_SQLITE_DIR:"${LIB_SQLITE_DIR} sed -i $BAK "s#\$(ROCKSPEC)#\$(ROCKSPEC) SQLITE_DIR=${LIB_SQLITE_DIR}#g" Makefile