diff --git a/README.md b/README.md index 2c4b089..66dd8af 100644 --- a/README.md +++ b/README.md @@ -43,17 +43,18 @@ apt-get install -y git apt update sudo su ``` -2. It is very important that the installer runs from the /opt directory! We will then want to get this repository and git clone it to the /opt directory. +2. Clone this repository to any directory of your choice. The installer will work from any location! ```sh -cd /opt git clone https://github.com/ShaYmez/hblink3-docker-install ``` -3. Now enter in to the cloned repo and execute the install script. No need to chmod as permissions are already satisfied. +**Note:** While you can clone to any directory, `/opt` is still recommended for consistency. + +3. Now enter into the cloned repo and execute the install script. No need to chmod as permissions are already satisfied. ```sh cd hblink3-docker-install ./hblink3-docker-install.sh ``` -4. follow the install and any prompts! It will prompt you for kernel updates if necessary. +4. Follow the install and any prompts! It will prompt you for kernel updates if necessary. 5. Once the installation is complete you will be presented with the first time run menu. Edit your config or exit to complete setup. ### New Menu System released with this installer! diff --git a/hblink3-docker-install.sh b/hblink3-docker-install.sh index e300bcd..221a04c 100755 --- a/hblink3-docker-install.sh +++ b/hblink3-docker-install.sh @@ -136,7 +136,7 @@ echo "Done." echo "------------------------------------------------------------------------------" echo "Installing control scripts /usr/local/sbin....." echo "------------------------------------------------------------------------------" - cd /opt/hblink3-docker-install/usr/local/sbin + cd "$DIRDIR/usr/local/sbin" cp -p menu /usr/local/sbin/hblink-menu cp -p flush /usr/local/sbin/hblink-flush cp -p update /usr/local/sbin/hblink-update @@ -167,6 +167,10 @@ fi chmod 755 /usr/local/sbin/hblink-restart chmod 755 /usr/local/sbin/hblink-initial-setup chmod 755 /usr/local/sbin/hblink-uninstall +# Save installer directory path for re-installation + mkdir -p /etc/hblink3 + echo "$DIRDIR" > /etc/hblink3/.installer_path + chmod 644 /etc/hblink3/.installer_path echo "Done." echo "------------------------------------------------------------------------------" diff --git a/usr/local/sbin/flush b/usr/local/sbin/flush index 365687c..2f27861 100755 --- a/usr/local/sbin/flush +++ b/usr/local/sbin/flush @@ -1,11 +1,12 @@ #!/bin/bash -# HBLINK3 DOCKER CONTROL SCRIPTS V1.9 +# HBLINK3 DOCKER CONTROL SCRIPTS V2.0 +# Version 13122025 # This script written by Shane Daley M0VUB. The script gracefully shuts down services while services are cleaned and logs are truncated. # We can also add items in this script for future use like updates or further log trims. # Add to the cron tab for auto execution -# Copyright (C) 2020 Shane P, Daley M0VUB +# Copyright (C) 2020-2025 Shane P. Daley M0VUB # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by diff --git a/usr/local/sbin/initial-setup b/usr/local/sbin/initial-setup index f14b0ba..1b9ae03 100755 --- a/usr/local/sbin/initial-setup +++ b/usr/local/sbin/initial-setup @@ -1,11 +1,12 @@ #!/bin/bash -# HBLINK3 DOCKER CONTROL SCRIPTS V1.9 +# HBLINK3 DOCKER CONTROL SCRIPTS V2.0 +# Version 13122025 # This script written by Shane Daley M0VUB. The script gracefully shuts down services while services are cleaned and logs are truncated. # We can also add items in this script for future use like updates or further log trims. # Add to the cron tab for auto execution -# Copyright (C) 2020 Shane P, Daley M0VUB +# Copyright (C) 2020-2025 Shane P. Daley M0VUB # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -19,7 +20,7 @@ # Initial Setup MENU system..... while : ; do -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 \ +menuopt=$(whiptail --title "INITIAL SETUP - HBLINK3 DOCKER V2.0" --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 " \ @@ -38,7 +39,15 @@ fi # Action case $menuopt in 1) -sudo /opt/hblink3-docker-install/hblink3-docker-install.sh ;; +# Read installer path from saved location, fallback to default if not found +INSTALLER_PATH=$(cat /etc/hblink3/.installer_path 2>/dev/null || echo "/opt/hblink3-docker-install") +if [ -f "$INSTALLER_PATH/hblink3-docker-install.sh" ]; then + sudo "$INSTALLER_PATH/hblink3-docker-install.sh" +else + echo "Error: Installer not found at $INSTALLER_PATH" + echo "Please ensure the installer directory still exists." + read -p "Press Enter to continue..." +fi ;; 2) sudo /usr/bin/bash ;; 3) diff --git a/usr/local/sbin/menu b/usr/local/sbin/menu index 6d7a04c..e01abd2 100755 --- a/usr/local/sbin/menu +++ b/usr/local/sbin/menu @@ -1,11 +1,12 @@ #!/bin/bash -# HBLINK3 DOCKER CONTROL SCRIPTS V1.9 +# HBLINK3 DOCKER CONTROL SCRIPTS V2.0 +# Version 13122025 # This script written by Shane Daley M0VUB. The script gracefully shuts down services while services are cleaned and logs are truncated. # We can also add items in this script for future use like updates or further log trims. # Add to the cron tab for auto execution -# Copyright (C) 2020 Shane P, Daley M0VUB +# Copyright (C) 2020-2025 Shane P. Daley M0VUB # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -19,7 +20,7 @@ # Main 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:" 24 56 14 \ +menuopt=$(whiptail --title "HBlink3 Control Version 2.0" --menu "Select option by using the up and down arrows on your keyboard. Once selected please press enter:" 24 56 14 \ 1 " Stop HBlink " \ 2 " Start HBlink " \ 3 " Restart HBlink " \ diff --git a/usr/local/sbin/restart b/usr/local/sbin/restart index e1328bc..cefc1c0 100755 --- a/usr/local/sbin/restart +++ b/usr/local/sbin/restart @@ -1,11 +1,12 @@ #!/bin/bash -# HBLINK3 DOCKER CONTROL SCRIPTS V1.9 +# HBLINK3 DOCKER CONTROL SCRIPTS V2.0 +# Version 13122025 # This script written by Shane Daley M0VUB. The script gracefully shuts down services while services are cleaned and logs are truncated. # We can also add items in this script for future use like updates or further log trims. # Add to the cron tab for auto execution -# Copyright (C) 2020 Shane P, Daley M0VUB +# Copyright (C) 2020-2025 Shane P. Daley M0VUB # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by diff --git a/usr/local/sbin/start b/usr/local/sbin/start index ea4a583..49c5720 100755 --- a/usr/local/sbin/start +++ b/usr/local/sbin/start @@ -1,11 +1,12 @@ #!/bin/bash -# HBLINK3 DOCKER CONTROL SCRIPTS V1.9 +# HBLINK3 DOCKER CONTROL SCRIPTS V2.0 +# Version 13122025 # This script written by Shane Daley M0VUB. The script gracefully shuts down services while services are cleaned and logs are truncated. # We can also add items in this script for future use like updates or further log trims. # Add to the cron tab for auto execution -# Copyright (C) 2020 Shane P, Daley M0VUB +# Copyright (C) 2020-2025 Shane P. Daley M0VUB # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by diff --git a/usr/local/sbin/stop b/usr/local/sbin/stop index 311b21b..edba73a 100755 --- a/usr/local/sbin/stop +++ b/usr/local/sbin/stop @@ -1,11 +1,12 @@ #!/bin/bash -# HBLINK3 DOCKER CONTROL SCRIPTS V1.9 +# HBLINK3 DOCKER CONTROL SCRIPTS V2.0 +# Version 13122025 # This script written by Shane Daley M0VUB. The script gracefully shuts down services while services are cleaned and logs are truncated. # We can also add items in this script for future use like updates or further log trims. # Add to the cron tab for auto execution -# Copyright (C) 2020 Shane P, Daley M0VUB +# Copyright (C) 2020-2025 Shane P. Daley M0VUB # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by diff --git a/usr/local/sbin/uninstall b/usr/local/sbin/uninstall index 6a6d168..42380fb 100644 --- a/usr/local/sbin/uninstall +++ b/usr/local/sbin/uninstall @@ -1,10 +1,11 @@ #!/bin/bash -# HBLINK3 DOCKER UNINSTALL SCRIPT V1.0 +# HBLINK3 DOCKER UNINSTALL SCRIPT V2.0 +# Version 13122025 # This script written by Shane Daley M0VUB. # This script gracefully removes HBlink3 installation and all related components. -# Copyright (C) 2024 Shane P. Daley M0VUB +# Copyright (C) 2020-2025 Shane P. Daley M0VUB # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by diff --git a/usr/local/sbin/update b/usr/local/sbin/update index 28b34c1..25a7c80 100755 --- a/usr/local/sbin/update +++ b/usr/local/sbin/update @@ -1,11 +1,12 @@ #!/bin/bash -# HBLINK3 DOCKER CONTROL SCRIPTS V1.9 +# HBLINK3 DOCKER CONTROL SCRIPTS V2.0 +# Version 13122025 # This script written by Shane Daley M0VUB. The script gracefully shuts down services while services are cleaned and logs are truncated. # We can also add items in this script for future use like updates or further log trims. # Add to the cron tab for auto execution -# Copyright (C) 2020 Shane P, Daley M0VUB +# Copyright (C) 2020-2025 Shane P. Daley M0VUB # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -68,7 +69,7 @@ echo "" echo " Your running on $ARC with Debian $VERSION " echo "" echo " Thanks for using this script. " -echo " Copyright © 2023 Shane Daley - M0VUB " +echo " Copyright © 2025 Shane Daley - M0VUB " echo " More information can be found @ https://freestar.network/development " echo "" echo "*************************************************************************" diff --git a/usr/local/sbin/upgrade b/usr/local/sbin/upgrade index 5cfb074..83d03f5 100755 --- a/usr/local/sbin/upgrade +++ b/usr/local/sbin/upgrade @@ -1,11 +1,12 @@ #!/bin/bash -# HBLINK3 DOCKER CONTROL SCRIPTS V1.9 +# HBLINK3 DOCKER CONTROL SCRIPTS V2.0 +# Version 13122025 # This script written by Shane Daley M0VUB. The script gracefully shuts down services while services are cleaned and logs are truncated. # We can also add items in this script for future use like updates or further log trims. # Add to the cron tab for auto execution -# Copyright (C) 2020 Shane P, Daley M0VUB +# Copyright (C) 2020-2025 Shane P. Daley M0VUB # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by