mirror of
https://github.com/ShaYmez/hblink3-docker-install.git
synced 2025-12-22 13:39:50 +13:00
Update initial-setup
Add initail commit
This commit is contained in:
parent
f85219df01
commit
5d84000276
@ -1 +1,72 @@
|
||||
#!/bin/bash
|
||||
|
||||
# HBLINK3 DOCKER CONTROL SCRIPTS V1.9
|
||||
# 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 <support@gb7nr.co.uk>
|
||||
#
|
||||
# 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
|
||||
# the Free Software Foundation; either version 3 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
|
||||
# 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:" 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)
|
||||
exitstatus=$?
|
||||
# Back-end HBlink3 menu
|
||||
if [ $exitstatus = 0 ]; then
|
||||
echo "You have chosen option:" $menuopt
|
||||
else
|
||||
echo "Type 'hblink-menu' to enter HBlink3 Control Menu "; break;
|
||||
fi
|
||||
# Action
|
||||
case $menuopt in
|
||||
1)
|
||||
sudo /usr/local/sbin/hblink-stop ;;
|
||||
2)
|
||||
sudo /usr/local/sbin/hblink-start ;;
|
||||
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)
|
||||
sudo nano /etc/hblink3/rules.py ;;
|
||||
8)
|
||||
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 ;
|
||||
esac
|
||||
done
|
||||
exit 0
|
||||
|
||||
# Wiptail menu system by ShaYmez https://github/ShaYmez
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user