From 4d4ff7b3e951ca049194eaac579d0a08e774757f Mon Sep 17 00:00:00 2001 From: M0VUB <76499782+ShaYmez@users.noreply.github.com> Date: Tue, 3 Jan 2023 23:49:49 +0000 Subject: [PATCH] Update initial-setup Re-factor for init setup syntax --- usr/local/sbin/initial-setup | 54 ++++++++++++++---------------------- 1 file changed, 21 insertions(+), 33 deletions(-) diff --git a/usr/local/sbin/initial-setup b/usr/local/sbin/initial-setup index 8592264..f14b0ba 100644 --- a/usr/local/sbin/initial-setup +++ b/usr/local/sbin/initial-setup @@ -17,21 +17,17 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -# Main MENU system..... +# Initial Setup MENU system..... while : ; do -menuopt=$(whiptail --title "HBlink3 Control Version 1.9PL" --menu "Select option by using the up and down arrows on your keyboard. Once selected please press enter:" 23 56 13 \ -1 " Stop HBlink " \ -2 " Start HBlink " \ -3 " Restart HBlink " \ -4 " Update HBlink / Docker " \ -5 " Flush HBlink / Truncate Logs " \ -6 " Edit HBlink Config " \ -7 " Edit HBlink Rules " \ -8 " Edit Dashboard Config " \ -9 " Full Upgrade OBPMaster " \ -10 " System Update / apt update " \ -11 " Reboot Entire Server " \ -12 " Shutdown Entire Server " 3>&1 1>&2 2>&3) +menuopt=$(whiptail --title "INTIAL SETUP - HBLINK3 DOCKER 1.9PL" --menu "Select option by using the up and down arrows on your keyboard. Once selected please press enter:" 23 56 13 \ +1 " Re-Install " \ +2 " Bash Shell (Type 'exit' to return to menu) " \ +3 " Edit HBlink Config " \ +4 " Edit HBlink Rules " \ +5 " Edit Dashboard Config (Advanced) " \ +6 " Edit Dashboard PHP Config (Advanced) " \ +7 " System Update / apt update " \ +8 " Finish Setup & Exit " 3>&1 1>&2 2>&3) exitstatus=$? # Back-end HBlink3 menu if [ $exitstatus = 0 ]; then @@ -42,31 +38,23 @@ fi # Action case $menuopt in 1) -sudo /usr/local/sbin/hblink-stop ;; +sudo /opt/hblink3-docker-install/hblink3-docker-install.sh ;; 2) -sudo /usr/local/sbin/hblink-start ;; +sudo /usr/bin/bash ;; 3) -sudo /usr/local/sbin/hblink-restart ;; -4) -sudo /usr/local/sbin/hblink-update ;; -5) -sudo /usr/local/sbin/hblink-flush ;; -6) sudo nano /etc/hblink3/hblink.cfg ;; -7) +4) sudo nano /etc/hblink3/rules.py ;; -8) +5) sudo nano /opt/HBMonv2/config.py ;; -9) -sudo /usr/local/sbin/hblink-upgrade ;; -10) -sudo apt-get update -y && sudo apt-get upgrade ;; -11) -sudo reboot ;; -12) -sudo shutdown now ; +6) +sudo nano /var/www/html/include/config.php ;; +7) +sudo apt update && apt upgrade ;; +8) +sudo hblink-flush && exit 0 ;; esac done exit 0 -# Wiptail menu system by ShaYmez https://github/ShaYmez +# Wiptail INITIAL SETUP by ShaYmez https://github/ShaYmez