From 7ef5a95c19fea3b1753bb2255dd5b595259e58ce Mon Sep 17 00:00:00 2001 From: Bozhidar Date: Sun, 28 Apr 2024 18:56:34 +0300 Subject: [PATCH] update --- installers/ubuntu-20.04/greeting.sh | 2 ++ installers/ubuntu-20.04/install-partial/download_web.sh | 2 ++ installers/ubuntu-20.04/install-partial/install_base.sh | 2 ++ installers/ubuntu-20.04/install-partial/install_log.sh | 2 ++ installers/ubuntu-20.04/install-partial/install_web.sh | 2 ++ installers/ubuntu-20.04/install.sh | 8 ++++++++ installers/ubuntu-22.04/greeting.sh | 2 ++ installers/ubuntu-22.04/install-partial/download_web.sh | 2 ++ installers/ubuntu-22.04/install-partial/install_base.sh | 2 ++ installers/ubuntu-22.04/install-partial/install_log.sh | 2 ++ installers/ubuntu-22.04/install-partial/install_web.sh | 2 ++ installers/ubuntu-22.04/install.sh | 8 ++++++++ 12 files changed, 36 insertions(+) diff --git a/installers/ubuntu-20.04/greeting.sh b/installers/ubuntu-20.04/greeting.sh index 40721c3..d172fd8 100644 --- a/installers/ubuntu-20.04/greeting.sh +++ b/installers/ubuntu-20.04/greeting.sh @@ -1,3 +1,5 @@ +#!/bin/bash + CURRENT_IP=$(curl -s ipinfo.io/ip) echo " \ diff --git a/installers/ubuntu-20.04/install-partial/download_web.sh b/installers/ubuntu-20.04/install-partial/download_web.sh index c3d9b77..cce3df4 100644 --- a/installers/ubuntu-20.04/install-partial/download_web.sh +++ b/installers/ubuntu-20.04/install-partial/download_web.sh @@ -1,3 +1,5 @@ +#!/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 88150c5..3e1b1ea 100644 --- a/installers/ubuntu-20.04/install-partial/install_base.sh +++ b/installers/ubuntu-20.04/install-partial/install_base.sh @@ -1,3 +1,5 @@ +#!/bin/bash + INSTALL_DIR="/phyre/install" apt-get update && apt-get install ca-certificates diff --git a/installers/ubuntu-20.04/install-partial/install_log.sh b/installers/ubuntu-20.04/install-partial/install_log.sh index 821d6be..78e2fe3 100755 --- a/installers/ubuntu-20.04/install-partial/install_log.sh +++ b/installers/ubuntu-20.04/install-partial/install_log.sh @@ -1,3 +1,5 @@ +#!/bin/bash + HOSTNAME=$(hostname) IP_ADDRESS=$(hostname -I | cut -d " " -f 1) diff --git a/installers/ubuntu-20.04/install-partial/install_web.sh b/installers/ubuntu-20.04/install-partial/install_web.sh index b9cd657..bea7521 100644 --- a/installers/ubuntu-20.04/install-partial/install_web.sh +++ b/installers/ubuntu-20.04/install-partial/install_web.sh @@ -1,3 +1,5 @@ +#!/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 0c804eb..3cfb83a 100644 --- a/installers/ubuntu-20.04/install.sh +++ b/installers/ubuntu-20.04/install.sh @@ -1,3 +1,5 @@ +#!/bin/bash + INSTALL_DIR="/phyre/install" apt-get update && apt-get install ca-certificates @@ -55,6 +57,8 @@ service phyre start PHYRE_PHP=/usr/local/phyre/php/bin/php ln -s $PHYRE_PHP /usr/bin/phyre-php +#!/bin/bash + HOSTNAME=$(hostname) IP_ADDRESS=$(hostname -I | cut -d " " -f 1) @@ -67,12 +71,16 @@ 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/greeting.sh b/installers/ubuntu-22.04/greeting.sh index f00c1fa..0ba48e2 100644 --- a/installers/ubuntu-22.04/greeting.sh +++ b/installers/ubuntu-22.04/greeting.sh @@ -1,3 +1,5 @@ +#!/bin/bash + CURRENT_IP=$(curl -s ipinfo.io/ip) echo " \ diff --git a/installers/ubuntu-22.04/install-partial/download_web.sh b/installers/ubuntu-22.04/install-partial/download_web.sh index c3d9b77..cce3df4 100644 --- a/installers/ubuntu-22.04/install-partial/download_web.sh +++ b/installers/ubuntu-22.04/install-partial/download_web.sh @@ -1,3 +1,5 @@ +#!/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 4f864ab..9a78935 100644 --- a/installers/ubuntu-22.04/install-partial/install_base.sh +++ b/installers/ubuntu-22.04/install-partial/install_base.sh @@ -1,3 +1,5 @@ +#!/bin/bash + INSTALL_DIR="/phyre/install" apt-get update && apt-get install ca-certificates diff --git a/installers/ubuntu-22.04/install-partial/install_log.sh b/installers/ubuntu-22.04/install-partial/install_log.sh index 821d6be..78e2fe3 100755 --- a/installers/ubuntu-22.04/install-partial/install_log.sh +++ b/installers/ubuntu-22.04/install-partial/install_log.sh @@ -1,3 +1,5 @@ +#!/bin/bash + HOSTNAME=$(hostname) IP_ADDRESS=$(hostname -I | cut -d " " -f 1) diff --git a/installers/ubuntu-22.04/install-partial/install_web.sh b/installers/ubuntu-22.04/install-partial/install_web.sh index b9cd657..bea7521 100644 --- a/installers/ubuntu-22.04/install-partial/install_web.sh +++ b/installers/ubuntu-22.04/install-partial/install_web.sh @@ -1,3 +1,5 @@ +#!/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 416c8bd..aa9895e 100644 --- a/installers/ubuntu-22.04/install.sh +++ b/installers/ubuntu-22.04/install.sh @@ -1,3 +1,5 @@ +#!/bin/bash + INSTALL_DIR="/phyre/install" apt-get update && apt-get install ca-certificates @@ -57,6 +59,8 @@ 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-22.04"}' +#!/bin/bash + HOSTNAME=$(hostname) IP_ADDRESS=$(hostname -I | cut -d " " -f 1) @@ -69,12 +73,16 @@ 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."