From 4ec55c64456f96390049de1af74df514abe4ee41 Mon Sep 17 00:00:00 2001 From: master3395 Date: Sat, 14 Feb 2026 22:57:39 +0100 Subject: [PATCH] Remove simple_install.sh; use official install.sh one-liner instead Co-authored-by: Cursor --- simple_install.sh | 122 --------------------- to-do/OLD-REPO-CHECKLIST-BEFORE-REMOVAL.md | 2 +- to-do/REPO-MERGE-2026-02-02.md | 2 +- 3 files changed, 2 insertions(+), 124 deletions(-) delete mode 100644 simple_install.sh diff --git a/simple_install.sh b/simple_install.sh deleted file mode 100644 index f22f256e2..000000000 --- a/simple_install.sh +++ /dev/null @@ -1,122 +0,0 @@ -#!/bin/sh - -# Simplified CyberPanel Installation Script -# Based on 2.4.4 approach with AlmaLinux 9 fixes - -OUTPUT=$(cat /etc/*release) - -# Detect OS and set appropriate variables -if echo $OUTPUT | grep -q "AlmaLinux 10" ; then - echo -e "\nDetecting AlmaLinux 10...\n" - SERVER_OS="AlmaLinux10" - PKG_MGR="dnf" -elif echo $OUTPUT | grep -q "AlmaLinux 9" ; then - echo -e "\nDetecting AlmaLinux 9...\n" - SERVER_OS="AlmaLinux9" - PKG_MGR="dnf" -elif echo $OUTPUT | grep -q "AlmaLinux 8" ; then - echo -e "\nDetecting AlmaLinux 8...\n" - SERVER_OS="AlmaLinux8" - PKG_MGR="dnf" -elif echo $OUTPUT | grep -q "Ubuntu 24.04" ; then - echo -e "\nDetecting Ubuntu 24.04...\n" - SERVER_OS="Ubuntu2404" - PKG_MGR="apt" -elif echo $OUTPUT | grep -q "Ubuntu 22.04" ; then - echo -e "\nDetecting Ubuntu 22.04...\n" - SERVER_OS="Ubuntu2204" - PKG_MGR="apt" -elif echo $OUTPUT | grep -q "Ubuntu 20.04" ; then - echo -e "\nDetecting Ubuntu 20.04...\n" - SERVER_OS="Ubuntu2004" - PKG_MGR="apt" -elif echo $OUTPUT | grep -q "CentOS Linux 8" ; then - echo -e "\nDetecting CentOS 8...\n" - SERVER_OS="CentOS8" - PKG_MGR="yum" -else - echo -e "\nUnsupported OS detected. This script supports:\n" - echo -e "AlmaLinux: 8, 9, 10\n" - echo -e "Ubuntu: 20.04, 22.04, 24.04\n" - echo -e "CentOS: 8\n" - exit 1 -fi - -echo "Installing basic dependencies..." - -# Install basic packages -if [ "$PKG_MGR" = "dnf" ]; then - dnf update -y - dnf install -y epel-release - dnf install -y wget curl unzip zip rsync firewalld git python3 python3-pip - dnf install -y mariadb-server mariadb-client - dnf install -y ImageMagick gd libicu oniguruma aspell libc-client -elif [ "$PKG_MGR" = "yum" ]; then - yum update -y - yum install -y epel-release - yum install -y wget curl unzip zip rsync firewalld git python3 python3-pip - yum install -y mariadb-server mariadb-client - yum install -y ImageMagick gd libicu oniguruma aspell libc-client -elif [ "$PKG_MGR" = "apt" ]; then - apt update -y - apt install -y wget curl unzip zip rsync git python3 python3-pip - apt install -y mariadb-server mariadb-client - apt install -y imagemagick php-gd php-intl php-mbstring php-pspell -fi - -# Start and enable MariaDB -echo "Starting MariaDB..." -systemctl enable mariadb -systemctl start mariadb - -# Create MySQL password file -echo "Setting up MySQL..." -mkdir -p /etc/cyberpanel -echo "cyberpanel123" > /etc/cyberpanel/mysqlPassword -chmod 600 /etc/cyberpanel/mysqlPassword - -# Secure MySQL installation -mysql -u root -e "ALTER USER 'root'@'localhost' IDENTIFIED BY 'cyberpanel123';" 2>/dev/null || true -mysql -u root -pcyberpanel123 -e "DELETE FROM mysql.user WHERE User='';" 2>/dev/null || true -mysql -u root -pcyberpanel123 -e "DELETE FROM mysql.user WHERE User='root' AND Host NOT IN ('localhost', '127.0.0.1', '::1');" 2>/dev/null || true -mysql -u root -pcyberpanel123 -e "DROP DATABASE IF EXISTS test;" 2>/dev/null || true -mysql -u root -pcyberpanel123 -e "DELETE FROM mysql.db WHERE Db='test' OR Db='test\\_%';" 2>/dev/null || true -mysql -u root -pcyberpanel123 -e "FLUSH PRIVILEGES;" 2>/dev/null || true - -# Configure firewall -echo "Configuring firewall..." -if [ "$PKG_MGR" = "dnf" ] || [ "$PKG_MGR" = "yum" ]; then - systemctl enable firewalld - systemctl start firewalld - firewall-cmd --permanent --add-port=8090/tcp - firewall-cmd --permanent --add-port=7080/tcp - firewall-cmd --permanent --add-port=80/tcp - firewall-cmd --permanent --add-port=443/tcp - firewall-cmd --permanent --add-port=21/tcp - firewall-cmd --permanent --add-port=25/tcp - firewall-cmd --permanent --add-port=587/tcp - firewall-cmd --permanent --add-port=465/tcp - firewall-cmd --permanent --add-port=110/tcp - firewall-cmd --permanent --add-port=143/tcp - firewall-cmd --permanent --add-port=993/tcp - firewall-cmd --permanent --add-port=995/tcp - firewall-cmd --permanent --add-port=53/tcp - firewall-cmd --permanent --add-port=53/udp - firewall-cmd --reload -fi - -# Download and install CyberPanel -echo "Downloading CyberPanel..." -rm -f cyberpanel.sh -curl --silent -o cyberpanel.sh "https://cyberpanel.sh/?dl&$SERVER_OS" 2>/dev/null - -if [ -f "cyberpanel.sh" ]; then - echo "Installing CyberPanel..." - chmod +x cyberpanel.sh - ./cyberpanel.sh -else - echo "Failed to download CyberPanel installer!" - exit 1 -fi - -echo "Installation completed!" diff --git a/to-do/OLD-REPO-CHECKLIST-BEFORE-REMOVAL.md b/to-do/OLD-REPO-CHECKLIST-BEFORE-REMOVAL.md index 39371c4fe..906cf1be3 100644 --- a/to-do/OLD-REPO-CHECKLIST-BEFORE-REMOVAL.md +++ b/to-do/OLD-REPO-CHECKLIST-BEFORE-REMOVAL.md @@ -35,7 +35,7 @@ These were only in the old fix and were copied into repo during the merge: | `cyberpanel_standalone.sh` | Standalone install script | | `fix_installation_issues.sh` | Installation fixes | | `install_phpmyadmin.sh` | phpMyAdmin installer | -| `simple_install.sh` | Simple installer | +| ~~`simple_install.sh`~~ | Removed – use official install.sh one-liner | | `INSTALLER_SUMMARY.md` | Installer docs | | `UNIVERSAL_OS_COMPATIBILITY.md` | OS compatibility docs | | `to-do/MARIADB_INSTALLATION_FIXES.md` | MariaDB fixes | diff --git a/to-do/REPO-MERGE-2026-02-02.md b/to-do/REPO-MERGE-2026-02-02.md index 79b96232e..9497772be 100644 --- a/to-do/REPO-MERGE-2026-02-02.md +++ b/to-do/REPO-MERGE-2026-02-02.md @@ -13,7 +13,7 @@ - `cyberpanel_standalone.sh` - `fix_installation_issues.sh` - `install_phpmyadmin.sh` - - `simple_install.sh` + - ~~`simple_install.sh`~~ (removed; use official install.sh) - `INSTALLER_SUMMARY.md` - `UNIVERSAL_OS_COMPATIBILITY.md` - `to-do/MARIADB_INSTALLATION_FIXES.md`