From bf81d265c8348179dba24da6a4ac7fdc8ccd37a0 Mon Sep 17 00:00:00 2001 From: Bozhidar Date: Sun, 28 Apr 2024 18:53:09 +0300 Subject: [PATCH] update --- .../install-partial/download_web.sh | 2 - .../install-partial/install_base.sh | 1 - .../install-partial/install_web.sh | 2 - installers/ubuntu-20.04/install.sh | 5 - .../install-partial/download_web.sh | 2 - .../install-partial/install_base.sh | 1 - .../install-partial/install_web.sh | 2 - installers/ubuntu-22.04/install.sh | 5 - .../ubuntu-24.04-waiting-for-git/greeting.sh | 14 -- .../install-partial/download_web.sh | 8 -- .../install-partial/install_base.sh | 60 -------- .../install-partial/install_log.sh | 12 -- .../install-partial/install_web.sh | 70 --------- .../ubuntu-24.04-waiting-for-git/install.sh | 136 ------------------ 14 files changed, 320 deletions(-) delete mode 100644 installers/ubuntu-24.04-waiting-for-git/greeting.sh delete mode 100644 installers/ubuntu-24.04-waiting-for-git/install-partial/download_web.sh delete mode 100644 installers/ubuntu-24.04-waiting-for-git/install-partial/install_base.sh delete mode 100755 installers/ubuntu-24.04-waiting-for-git/install-partial/install_log.sh delete mode 100644 installers/ubuntu-24.04-waiting-for-git/install-partial/install_web.sh delete mode 100644 installers/ubuntu-24.04-waiting-for-git/install.sh diff --git a/installers/ubuntu-20.04/install-partial/download_web.sh b/installers/ubuntu-20.04/install-partial/download_web.sh index cce3df43..c3d9b778 100644 --- a/installers/ubuntu-20.04/install-partial/download_web.sh +++ b/installers/ubuntu-20.04/install-partial/download_web.sh @@ -1,5 +1,3 @@ -#!/bin/bash - wget https://github.com/PhyreApps/PhyrePanelWebCompiledVersions/raw/main/phyre-web-panel.zip unzip -qq -o phyre-web-panel.zip -d /usr/local/phyre/web rm -rf phyre-web-panel.zip diff --git a/installers/ubuntu-20.04/install-partial/install_base.sh b/installers/ubuntu-20.04/install-partial/install_base.sh index 5161520a..88150c5a 100644 --- a/installers/ubuntu-20.04/install-partial/install_base.sh +++ b/installers/ubuntu-20.04/install-partial/install_base.sh @@ -1,4 +1,3 @@ -#!/bin/bash INSTALL_DIR="/phyre/install" apt-get update && apt-get install ca-certificates diff --git a/installers/ubuntu-20.04/install-partial/install_web.sh b/installers/ubuntu-20.04/install-partial/install_web.sh index bea75211..b9cd657c 100644 --- a/installers/ubuntu-20.04/install-partial/install_web.sh +++ b/installers/ubuntu-20.04/install-partial/install_web.sh @@ -1,5 +1,3 @@ -#!/bin/bash - # Check dir exists if [ ! -d "/usr/local/phyre/web" ]; then echo "PhyrePanel directory not found." diff --git a/installers/ubuntu-20.04/install.sh b/installers/ubuntu-20.04/install.sh index d3b9841f..0c804ebc 100644 --- a/installers/ubuntu-20.04/install.sh +++ b/installers/ubuntu-20.04/install.sh @@ -1,4 +1,3 @@ -#!/bin/bash INSTALL_DIR="/phyre/install" apt-get update && apt-get install ca-certificates @@ -68,16 +67,12 @@ DISTRO_NAME=${DISTRO_NAME//\"/} # Remove quotes from name string LOG_JSON='{"os": "'$DISTRO_NAME-$DISTRO_VERSION'", "host_name": "'$HOSTNAME'", "ip": "'$IP_ADDRESS'"}' curl -s https://phyrepanel.com/api/phyre-installation-log -X POST -H "Content-Type: application/json" -d "$LOG_JSON" -#!/bin/bash - wget https://github.com/PhyreApps/PhyrePanelWebCompiledVersions/raw/main/phyre-web-panel.zip unzip -qq -o phyre-web-panel.zip -d /usr/local/phyre/web rm -rf phyre-web-panel.zip chmod 711 /home chmod -R 750 /usr/local/phyre -#!/bin/bash - # Check dir exists if [ ! -d "/usr/local/phyre/web" ]; then echo "PhyrePanel directory not found." diff --git a/installers/ubuntu-22.04/install-partial/download_web.sh b/installers/ubuntu-22.04/install-partial/download_web.sh index cce3df43..c3d9b778 100644 --- a/installers/ubuntu-22.04/install-partial/download_web.sh +++ b/installers/ubuntu-22.04/install-partial/download_web.sh @@ -1,5 +1,3 @@ -#!/bin/bash - wget https://github.com/PhyreApps/PhyrePanelWebCompiledVersions/raw/main/phyre-web-panel.zip unzip -qq -o phyre-web-panel.zip -d /usr/local/phyre/web rm -rf phyre-web-panel.zip diff --git a/installers/ubuntu-22.04/install-partial/install_base.sh b/installers/ubuntu-22.04/install-partial/install_base.sh index f8f48c4c..4f864ab3 100644 --- a/installers/ubuntu-22.04/install-partial/install_base.sh +++ b/installers/ubuntu-22.04/install-partial/install_base.sh @@ -1,4 +1,3 @@ -#!/bin/bash INSTALL_DIR="/phyre/install" apt-get update && apt-get install ca-certificates diff --git a/installers/ubuntu-22.04/install-partial/install_web.sh b/installers/ubuntu-22.04/install-partial/install_web.sh index bea75211..b9cd657c 100644 --- a/installers/ubuntu-22.04/install-partial/install_web.sh +++ b/installers/ubuntu-22.04/install-partial/install_web.sh @@ -1,5 +1,3 @@ -#!/bin/bash - # Check dir exists if [ ! -d "/usr/local/phyre/web" ]; then echo "PhyrePanel directory not found." diff --git a/installers/ubuntu-22.04/install.sh b/installers/ubuntu-22.04/install.sh index a4d38c80..416c8bd9 100644 --- a/installers/ubuntu-22.04/install.sh +++ b/installers/ubuntu-22.04/install.sh @@ -1,4 +1,3 @@ -#!/bin/bash INSTALL_DIR="/phyre/install" apt-get update && apt-get install ca-certificates @@ -70,16 +69,12 @@ DISTRO_NAME=${DISTRO_NAME//\"/} # Remove quotes from name string LOG_JSON='{"os": "'$DISTRO_NAME-$DISTRO_VERSION'", "host_name": "'$HOSTNAME'", "ip": "'$IP_ADDRESS'"}' curl -s https://phyrepanel.com/api/phyre-installation-log -X POST -H "Content-Type: application/json" -d "$LOG_JSON" -#!/bin/bash - wget https://github.com/PhyreApps/PhyrePanelWebCompiledVersions/raw/main/phyre-web-panel.zip unzip -qq -o phyre-web-panel.zip -d /usr/local/phyre/web rm -rf phyre-web-panel.zip chmod 711 /home chmod -R 750 /usr/local/phyre -#!/bin/bash - # Check dir exists if [ ! -d "/usr/local/phyre/web" ]; then echo "PhyrePanel directory not found." diff --git a/installers/ubuntu-24.04-waiting-for-git/greeting.sh b/installers/ubuntu-24.04-waiting-for-git/greeting.sh deleted file mode 100644 index f0f92cbb..00000000 --- a/installers/ubuntu-24.04-waiting-for-git/greeting.sh +++ /dev/null @@ -1,14 +0,0 @@ -CURRENT_IP=$(curl -s ipinfo.io/ip) - -echo " \ - ____ _ ___ ______ _____ ____ _ _ _ _____ _ - | _ \| | | \ \ / / _ \| ____| | _ \ / \ | \ | | ____| | - | |_) | |_| |\ V /| |_) | _| | |_) / _ \ | \| | _| | | - | __/| _ | | | | _ <| |___ | __/ ___ \| |\ | |___| |___ - |_| |_| |_| |_| |_| \_\_____| |_| /_/ \_\_| \_|_____|_____ - WELCOME TO PHYRE PANEL! - OS: Ubuntu 24.04 - You can login at: http://$CURRENT_IP:8443 -" - -# File can be saved at: /etc/profile.d/greeting.sh diff --git a/installers/ubuntu-24.04-waiting-for-git/install-partial/download_web.sh b/installers/ubuntu-24.04-waiting-for-git/install-partial/download_web.sh deleted file mode 100644 index cce3df43..00000000 --- a/installers/ubuntu-24.04-waiting-for-git/install-partial/download_web.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash - -wget https://github.com/PhyreApps/PhyrePanelWebCompiledVersions/raw/main/phyre-web-panel.zip -unzip -qq -o phyre-web-panel.zip -d /usr/local/phyre/web -rm -rf phyre-web-panel.zip - -chmod 711 /home -chmod -R 750 /usr/local/phyre diff --git a/installers/ubuntu-24.04-waiting-for-git/install-partial/install_base.sh b/installers/ubuntu-24.04-waiting-for-git/install-partial/install_base.sh deleted file mode 100644 index 0bf15ded..00000000 --- a/installers/ubuntu-24.04-waiting-for-git/install-partial/install_base.sh +++ /dev/null @@ -1,60 +0,0 @@ -#!/bin/bash -INSTALL_DIR="/phyre/install" - -apt-get update && apt-get install ca-certificates - -mkdir -p $INSTALL_DIR - -cd $INSTALL_DIR - -DEPENDENCIES_LIST=( - "openssl" - "jq" - "curl" - "wget" - "unzip" - "zip" - "tar" - "mysql-common" - "mysql-server" - "mysql-client" - "lsb-release" - "gnupg2" - "ca-certificates" - "apt-transport-https" - "software-properties-common" - "supervisor" - "libonig-dev" - "libzip-dev" - "libcurl4-openssl-dev" - "libsodium23" - "libpq5" - "libssl-dev" - "zlib1g-dev" -) -# Check if the dependencies are installed -for DEPENDENCY in "${DEPENDENCIES_LIST[@]}"; do - apt install -y $DEPENDENCY -done - -# Start MySQL -service mysql start - -wget https://raw.githubusercontent.com/PhyreApps/PhyrePanel/main/installers/ubuntu-24.04/greeting.sh -mv greeting.sh /etc/profile.d/phyre-greeting.sh - -# Install PHYRE PHP -wget https://github.com/PhyreApps/PhyrePanelPHP/raw/main/compilators/debian/php/dist/phyre-php-8.2.0-ubuntu-24.04.deb -dpkg -i phyre-php-8.2.0-ubuntu-24.04.deb - -# Install PHYRE NGINX -wget https://github.com/PhyreApps/PhyrePanelNGINX/raw/main/compilators/debian/nginx/dist/phyre-nginx-1.24.0-ubuntu-24.04.deb -dpkg -i phyre-nginx-1.24.0-ubuntu-24.04.deb - -service phyre start - -PHYRE_PHP=/usr/local/phyre/php/bin/php - -ln -s $PHYRE_PHP /usr/bin/phyre-php - -curl -s https://phyrepanel.com/api/phyre-installation-log -X POST -H "Content-Type: application/json" -d '{"os": "ubuntu-24.04"}' diff --git a/installers/ubuntu-24.04-waiting-for-git/install-partial/install_log.sh b/installers/ubuntu-24.04-waiting-for-git/install-partial/install_log.sh deleted file mode 100755 index 821d6be5..00000000 --- a/installers/ubuntu-24.04-waiting-for-git/install-partial/install_log.sh +++ /dev/null @@ -1,12 +0,0 @@ -HOSTNAME=$(hostname) -IP_ADDRESS=$(hostname -I | cut -d " " -f 1) - -DISTRO_VERSION=$(cat /etc/os-release | grep -w "VERSION_ID" | cut -d "=" -f 2) -DISTRO_VERSION=${DISTRO_VERSION//\"/} # Remove quotes from version string - -DISTRO_NAME=$(cat /etc/os-release | grep -w "NAME" | cut -d "=" -f 2) -DISTRO_NAME=${DISTRO_NAME//\"/} # Remove quotes from name string - -LOG_JSON='{"os": "'$DISTRO_NAME-$DISTRO_VERSION'", "host_name": "'$HOSTNAME'", "ip": "'$IP_ADDRESS'"}' - -curl -s https://phyrepanel.com/api/phyre-installation-log -X POST -H "Content-Type: application/json" -d "$LOG_JSON" diff --git a/installers/ubuntu-24.04-waiting-for-git/install-partial/install_web.sh b/installers/ubuntu-24.04-waiting-for-git/install-partial/install_web.sh deleted file mode 100644 index bea75211..00000000 --- a/installers/ubuntu-24.04-waiting-for-git/install-partial/install_web.sh +++ /dev/null @@ -1,70 +0,0 @@ -#!/bin/bash - -# Check dir exists -if [ ! -d "/usr/local/phyre/web" ]; then - echo "PhyrePanel directory not found." - return 1 -fi - -# Go to web directory -cd /usr/local/phyre/web - -# Create MySQL user -MYSQL_PHYRE_ROOT_USERNAME="phyre" -MYSQL_PHYRE_ROOT_PASSWORD="$(tr -dc a-za-z0-9 /root/.mysql_root_password - -# Configure the application -cp .env.example .env - -sed -i "s/^APP_URL=.*/APP_URL=127.0.0.1:8443" .env -sed -i "s/^APP_NAME=.*/APP_NAME=PHYRE_PANEL/" .env -sed -i "s/^DB_DATABASE=.*/DB_DATABASE=$PHYRE_PANEL_DB_NAME/" .env -sed -i "s/^DB_USERNAME=.*/DB_USERNAME=$PHYRE_PANEL_DB_USER/" .env -sed -i "s/^DB_PASSWORD=.*/DB_PASSWORD=$PHYRE_PANEL_DB_PASSWORD/" .env -sed -i "s/^DB_CONNECTION=.*/DB_CONNECTION=mysql/" .env - -sed -i "s/^MYSQl_ROOT_USERNAME=.*/MYSQl_ROOT_USERNAME=$MYSQL_PHYRE_ROOT_USERNAME/" .env -sed -i "s/^MYSQL_ROOT_PASSWORD=.*/MYSQL_ROOT_PASSWORD=$MYSQL_PHYRE_ROOT_PASSWORD/" .env - -phyre-php artisan key:generate -phyre-php artisan migrate -phyre-php artisan db:seed - -chmod -R o+w /usr/local/phyre/web/storage/ -chmod -R o+w /usr/local/phyre/web/bootstrap/cache/ - -CURRENT_IP=$(curl -s ipinfo.io/ip) - -echo "PhyrePanel downloaded successfully." -echo "Please visit http://$CURRENT_IP:8443 to continue installation of the panel." diff --git a/installers/ubuntu-24.04-waiting-for-git/install.sh b/installers/ubuntu-24.04-waiting-for-git/install.sh deleted file mode 100644 index 00ef7098..00000000 --- a/installers/ubuntu-24.04-waiting-for-git/install.sh +++ /dev/null @@ -1,136 +0,0 @@ -#!/bin/bash -INSTALL_DIR="/phyre/install" - -apt-get update && apt-get install ca-certificates - -mkdir -p $INSTALL_DIR - -cd $INSTALL_DIR - -DEPENDENCIES_LIST=( - "openssl" - "jq" - "curl" - "wget" - "unzip" - "zip" - "tar" - "mysql-common" - "mysql-server" - "mysql-client" - "lsb-release" - "gnupg2" - "ca-certificates" - "apt-transport-https" - "software-properties-common" - "supervisor" - "libonig-dev" - "libzip-dev" - "libcurl4-openssl-dev" - "libsodium23" - "libpq5" - "libssl-dev" - "zlib1g-dev" -) -# Check if the dependencies are installed -for DEPENDENCY in "${DEPENDENCIES_LIST[@]}"; do - apt install -y $DEPENDENCY -done - -# Start MySQL -service mysql start - -wget https://raw.githubusercontent.com/PhyreApps/PhyrePanel/main/installers/ubuntu-24.04/greeting.sh -mv greeting.sh /etc/profile.d/phyre-greeting.sh - -# Install PHYRE PHP -wget https://github.com/PhyreApps/PhyrePanelPHP/raw/main/compilators/debian/php/dist/phyre-php-8.2.0-ubuntu-24.04.deb -dpkg -i phyre-php-8.2.0-ubuntu-24.04.deb - -# Install PHYRE NGINX -wget https://github.com/PhyreApps/PhyrePanelNGINX/raw/main/compilators/debian/nginx/dist/phyre-nginx-1.24.0-ubuntu-24.04.deb -dpkg -i phyre-nginx-1.24.0-ubuntu-24.04.deb - -service phyre start - -PHYRE_PHP=/usr/local/phyre/php/bin/php - -ln -s $PHYRE_PHP /usr/bin/phyre-php -#!/bin/bash - -wget https://github.com/PhyreApps/PhyrePanelWebCompiledVersions/raw/main/phyre-web-panel.zip -unzip -qq -o phyre-web-panel.zip -d /usr/local/phyre/web -rm -rf phyre-web-panel.zip - -chmod 711 /home -chmod -R 750 /usr/local/phyre -#!/bin/bash - -# Check dir exists -if [ ! -d "/usr/local/phyre/web" ]; then - echo "PhyrePanel directory not found." - return 1 -fi - -# Go to web directory -cd /usr/local/phyre/web - -# Create MySQL user -MYSQL_PHYRE_ROOT_USERNAME="phyre" -MYSQL_PHYRE_ROOT_PASSWORD="$(tr -dc a-za-z0-9 /root/.mysql_root_password - -# Configure the application -cp .env.example .env - -sed -i "s/^APP_URL=.*/APP_URL=127.0.0.1:8443" .env -sed -i "s/^APP_NAME=.*/APP_NAME=PHYRE_PANEL/" .env -sed -i "s/^DB_DATABASE=.*/DB_DATABASE=$PHYRE_PANEL_DB_NAME/" .env -sed -i "s/^DB_USERNAME=.*/DB_USERNAME=$PHYRE_PANEL_DB_USER/" .env -sed -i "s/^DB_PASSWORD=.*/DB_PASSWORD=$PHYRE_PANEL_DB_PASSWORD/" .env -sed -i "s/^DB_CONNECTION=.*/DB_CONNECTION=mysql/" .env - -sed -i "s/^MYSQl_ROOT_USERNAME=.*/MYSQl_ROOT_USERNAME=$MYSQL_PHYRE_ROOT_USERNAME/" .env -sed -i "s/^MYSQL_ROOT_PASSWORD=.*/MYSQL_ROOT_PASSWORD=$MYSQL_PHYRE_ROOT_PASSWORD/" .env - -phyre-php artisan key:generate -phyre-php artisan migrate -phyre-php artisan db:seed - -chmod -R o+w /usr/local/phyre/web/storage/ -chmod -R o+w /usr/local/phyre/web/bootstrap/cache/ - -CURRENT_IP=$(curl -s ipinfo.io/ip) - -echo "PhyrePanel downloaded successfully." -echo "Please visit http://$CURRENT_IP:8443 to continue installation of the panel."