From 5125a3a073d03e3de5c37ca848a4694aed8197be Mon Sep 17 00:00:00 2001 From: qtwrk Date: Mon, 24 May 2021 00:46:48 +0200 Subject: [PATCH 1/5] Update install.py --- install/install.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/install/install.py b/install/install.py index 4d7870bce..04c187af1 100755 --- a/install/install.py +++ b/install/install.py @@ -55,6 +55,8 @@ def get_distro(): return cent8 if data.find('AlmaLinux release 8') > -1: return cent8 + if data.find('Rocky Linux release 8') > -1: + return cent8 else: logging.InstallLog.writeToFile("Can't find linux release file - fatal error") From 1a8230e4bad53fbeb8aa079fadcfe804c4e0858b Mon Sep 17 00:00:00 2001 From: qtwrk Date: Mon, 24 May 2021 00:48:50 +0200 Subject: [PATCH 2/5] Update cyberpanel.sh --- cyberpanel.sh | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/cyberpanel.sh b/cyberpanel.sh index c92925b7e..e013eb03e 100644 --- a/cyberpanel.sh +++ b/cyberpanel.sh @@ -5,7 +5,7 @@ #set -u -#CyberPanel installer script for CentOS 7.X, CentOS 8.X, CloudLinux 7.X, Ubuntu 18.04, Ubuntu 20.04 , Ubuntu 20.10 and AlmaLinux 8.X +#CyberPanel installer script for CentOS 7.X, CentOS 8.X, CloudLinux 7.X, RockyLinux 8.X, Ubuntu 18.04, Ubuntu 20.04 , Ubuntu 20.10 and AlmaLinux 8.X #For whoever may edit this script, please follow : #Please use Pre_Install_xxx() and Post_Install_xxx() if you want to something respectively before or after the panel installation #and update below accordingly @@ -16,7 +16,7 @@ #Set_Default_Variables() ---> set some default variable for later use #Check_Root() ---> check for root #Check_Server_IP() ---> check for server IP and geolocation at country level -#Check_OS() ---> check system , support on centos7/8 ubutnu18/20 and cloudlinux 7 , 8 is untested. +#Check_OS() ---> check system , support on centos7/8, rockylinux 8.x , almalinux 8.x ubutnu18/20 and cloudlinux 7 , 8 is untested. #Check_Virtualization() ---> check for virtualizaon , #LXC not supported# , some edit needed on OVZ #Check_Panel() ---> check to make sure no other panel is installed #Check_Process() ---> check no other process like Apache is running @@ -245,12 +245,14 @@ elif grep -q "AlmaLinux-8" /etc/os-release ; then Server_OS="AlmaLinux" elif grep -q -E "CloudLinux 7|CloudLinux 8" /etc/os-release ; then Server_OS="CloudLinux" +elif grep -q -E "Rocky Linux" /etc/os-release ; then + Server_OS="RockyLinux" elif grep -q -E "Ubuntu 18.04|Ubuntu 20.04|Ubuntu 20.10" /etc/os-release ; then Server_OS="Ubuntu" else echo -e "Unable to detect your system..." - echo -e "\nCyberPanel is supported on Ubuntu 18.04 x86_64, Ubuntu 20.04 x86_64, Ubuntu 20.10 x86_64, CentOS 7.x, CentOS 8.x, AlmaLinux 8.x and CloudLinux 7.x...\n" - Debug_Log2 "CyberPanel is supported on Ubuntu 18.04 x86_64, Ubuntu 20.04 x86_64, Ubuntu 20.10 x86_64, CentOS 7.x, CentOS 8.x, AlmaLinux 8.x and CloudLinux 7.x... [404]" + echo -e "\nCyberPanel is supported on Ubuntu 18.04 x86_64, Ubuntu 20.04 x86_64, Ubuntu 20.10 x86_64, CentOS 7.x, CentOS 8.x, AlmaLinux 8.x, RockyLinux 8.x and CloudLinux 7.x...\n" + Debug_Log2 "CyberPanel is supported on Ubuntu 18.04 x86_64, Ubuntu 20.04 x86_64, Ubuntu 20.10 x86_64, CentOS 7.x, CentOS 8.x, AlmaLinux 8.x, RockyLinux 8.x and CloudLinux 7.x... [404]" exit fi @@ -259,10 +261,10 @@ Server_OS_Version=$(grep VERSION_ID /etc/os-release | awk -F[=,] '{print $2}' | echo -e "System: $Server_OS $Server_OS_Version detected...\n" -if [[ $Server_OS = "CloudLinux" ]] || [[ "$Server_OS" = "AlmaLinux" ]] ; then +if [[ $Server_OS = "CloudLinux" ]] || [[ "$Server_OS" = "AlmaLinux" ]] || [[ "$Server_OS" = "RockyLinux" ]] ; then Server_OS="CentOS" #CloudLinux gives version id like 7.8 , 7.9 , so cut it to show first number only - #treat CL and Alma as CentOS + #treat CL , Rocky and Alma as CentOS fi if [[ "$Debug" = "On" ]] ; then @@ -412,7 +414,7 @@ echo -e "\nThis will install LiteSpeed Enterise , replace LICENSE_KEY to actual Check_Argument() { if [[ "$#" = "0" ]] || [[ "$#" = "1" && "$1" = "--debug" ]] || [[ "$#" = "1" && "$1" = "--mirror" ]]; then - echo -e "\nInitializing...\n" + echo -e "\nInitialized...\n" else if [[ $1 = "help" ]]; then Show_Help @@ -1064,7 +1066,13 @@ if [[ "$Server_OS" = "CentOS" ]] ; then fi #CentOS 7 specific change if [[ "$Server_OS_Version" = "8" ]] ; then - : + if grep -q -E "Rocky Linux" /etc/os-release ; then + if [[ "$Server_Country" = "CN" ]] ; then + sed -i 's|rpm -Uvh http://rpms.litespeedtech.com/centos/litespeed-repo-1.1-1.el8.noarch.rpm|curl -o /etc/yum.repos.d/litespeed.repo https://cyberpanel.sh/litespeed/litespeed_cn.repo|g' install.py + else + sed -i 's|rpm -Uvh http://rpms.litespeedtech.com/centos/litespeed-repo-1.1-1.el8.noarch.rpm|curl -o /etc/yum.repos.d/litespeed.repo https://cyberpanel.sh/litespeed/litespeed.repo|g' install.py + fi + fi fi #CentOS 8 specific change From 650abb5c9c6f0be4ba8d072df4dd7d5c82af377c Mon Sep 17 00:00:00 2001 From: qtwrk Date: Mon, 24 May 2021 00:50:27 +0200 Subject: [PATCH 3/5] Update cyberpanel.sh --- cyberpanel.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cyberpanel.sh b/cyberpanel.sh index e013eb03e..f818dacf5 100644 --- a/cyberpanel.sh +++ b/cyberpanel.sh @@ -251,8 +251,8 @@ elif grep -q -E "Ubuntu 18.04|Ubuntu 20.04|Ubuntu 20.10" /etc/os-release ; then Server_OS="Ubuntu" else echo -e "Unable to detect your system..." - echo -e "\nCyberPanel is supported on Ubuntu 18.04 x86_64, Ubuntu 20.04 x86_64, Ubuntu 20.10 x86_64, CentOS 7.x, CentOS 8.x, AlmaLinux 8.x, RockyLinux 8.x and CloudLinux 7.x...\n" - Debug_Log2 "CyberPanel is supported on Ubuntu 18.04 x86_64, Ubuntu 20.04 x86_64, Ubuntu 20.10 x86_64, CentOS 7.x, CentOS 8.x, AlmaLinux 8.x, RockyLinux 8.x and CloudLinux 7.x... [404]" + echo -e "\nCyberPanel is supported on Ubuntu 18.04 x86_64, Ubuntu 20.04 x86_64, Ubuntu 20.10 x86_64, CentOS 7.x, CentOS 8.x, AlmaLinux 8.x, RockyLinux 8.x, CloudLinux 7.x, CloudLinux 8.x...\n" + Debug_Log2 "CyberPanel is supported on Ubuntu 18.04 x86_64, Ubuntu 20.04 x86_64, Ubuntu 20.10 x86_64, CentOS 7.x, CentOS 8.x, AlmaLinux 8.x, RockyLinux 8.x, CloudLinux 7.x, CloudLinux 8.x... [404]" exit fi From 7670c6599ba12b50442e7ae6b9f2e1e48c7d5557 Mon Sep 17 00:00:00 2001 From: qtwrk Date: Mon, 24 May 2021 00:51:28 +0200 Subject: [PATCH 4/5] Update cyberpanel.sh --- cyberpanel.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/cyberpanel.sh b/cyberpanel.sh index f818dacf5..0d4b3d41d 100644 --- a/cyberpanel.sh +++ b/cyberpanel.sh @@ -1448,6 +1448,7 @@ fi if pgrep "redis" ; then echo -e "\n\nRedis installed and running..." + touch /home/cyberpanel/redis fi } From 579af0738d55f781985df5b60ee34d4033450b1d Mon Sep 17 00:00:00 2001 From: qtwrk Date: Tue, 25 May 2021 16:17:12 +0200 Subject: [PATCH 5/5] fix issue on Alibaba Cloud fix issue on Alibaba Cloud --- cyberpanel.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cyberpanel.sh b/cyberpanel.sh index 0d4b3d41d..5c672a5b6 100644 --- a/cyberpanel.sh +++ b/cyberpanel.sh @@ -973,6 +973,9 @@ if [[ "$Server_OS" = "CentOS" ]] ; then else apt update -y DEBIAN_FRONTEND=noninteractive apt upgrade -y -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" + if [[ "$Server_Provider" = "Alibaba Cloud" ]] ; then + apt install -y --allow-downgrades libgnutls30=3.6.13-2ubuntu1.3 + fi DEBIAN_FRONTEND=noninteracitve apt install -y dnsutils net-tools htop telnet libcurl4-gnutls-dev libgnutls28-dev libgcrypt20-dev libattr1 libattr1-dev liblzma-dev libgpgme-dev libmariadbclient-dev libcurl4-gnutls-dev libssl-dev nghttp2 libnghttp2-dev idn2 libidn2-dev libidn2-0-dev librtmp-dev libpsl-dev nettle-dev libgnutls28-dev libldap2-dev libgssapi-krb5-2 libk5crypto3 libkrb5-dev libcomerr2 libldap2-dev virtualenv git socat vim unzip zip Check_Return