diff --git a/install-custom-cyberpanel.sh b/install-custom-cyberpanel.sh new file mode 100644 index 000000000..18c0fb6ac --- /dev/null +++ b/install-custom-cyberpanel.sh @@ -0,0 +1,71 @@ +#!/bin/sh + +# Custom CyberPanel Installer for jabirMahmoud's fork +# This script installs your custom CyberPanel instead of the official one + +OUTPUT=$(cat /etc/*release) +if echo $OUTPUT | grep -q "CentOS Linux 7" ; then + echo "Checking and installing curl and wget" +yum install curl wget -y 1> /dev/null +yum update curl wget ca-certificates -y 1> /dev/null + SERVER_OS="CentOS" +elif echo $OUTPUT | grep -q "CentOS Linux 8" ; then + echo -e "\nDetecting Centos 8...\n" + SERVER_OS="CentOS8" +yum install curl wget -y 1> /dev/null +yum update curl wget ca-certificates -y 1> /dev/null +elif echo $OUTPUT | grep -q "AlmaLinux 8" ; then + echo -e "\nDetecting AlmaLinux 8...\n" + SERVER_OS="CentOS8" +yum install curl wget -y 1> /dev/null +yum update curl wget ca-certificates -y 1> /dev/null +elif echo $OUTPUT | grep -q "AlmaLinux 9" ; then + echo -e "\nDetecting AlmaLinux 9...\n" + SERVER_OS="CentOS8" +yum install curl wget -y 1> /dev/null +yum update curl wget ca-certificates -y 1> /dev/null +elif echo $OUTPUT | grep -q "AlmaLinux 10" ; then + echo -e "\nDetecting AlmaLinux 10...\n" + SERVER_OS="CentOS8" +yum install curl wget -y 1> /dev/null +yum update curl wget ca-certificates -y 1> /dev/null +elif echo $OUTPUT | grep -q "CloudLinux 7" ; then + echo "Checking and installing curl and wget" +yum install curl wget -y 1> /dev/null +yum update curl wget ca-certificates -y 1> /dev/null + SERVER_OS="CloudLinux" +elif echo $OUTPUT | grep -q "CloudLinux 8" ; then + echo "Checking and installing curl and wget" +yum install curl wget -y 1> /dev/null +yum update curl wget ca-certificates -y 1> /dev/null + SERVER_OS="CloudLinux" +elif echo $OUTPUT | grep -q "Ubuntu 18.04" ; then +apt install -y -qq wget curl + SERVER_OS="Ubuntu" +elif echo $OUTPUT | grep -q "Ubuntu 20.04" ; then +apt install -y -qq wget curl + SERVER_OS="Ubuntu" +elif echo $OUTPUT | grep -q "Ubuntu 22.04" ; then +apt install -y -qq wget curl + SERVER_OS="Ubuntu" +elif echo $OUTPUT | grep -q "Ubuntu 24.04" ; then +apt install -y -qq wget curl + SERVER_OS="Ubuntu" +else + echo -e "\nUnable to detect your OS...\n" + echo -e "\nCyberPanel is supported on Ubuntu 18.04, Ubuntu 20.04 Ubuntu 22.04, Ubuntu 24.04, AlmaLinux 8, AlmaLinux 9, AlmaLinux 10 and CloudLinux 7.x...\n" + exit 1 +fi + +echo "Installing Custom CyberPanel from jabirMahmoud's fork..." + +# Download your custom cyberpanel.sh script +rm -f cyberpanel-custom.sh +curl --silent -o cyberpanel-custom.sh "https://raw.githubusercontent.com/jabirMahmoud/cyberpanel/master/cyberpanel.sh" 2>/dev/null + +# Modify the script to use your fork +sed -i 's|https://github.com/usmannasir/cyberpanel|https://github.com/jabirMahmoud/cyberpanel|g' cyberpanel-custom.sh +sed -i 's|usmannasir|jabirMahmoud|g' cyberpanel-custom.sh + +chmod +x cyberpanel-custom.sh +./cyberpanel-custom.sh $@