mirror of
https://github.com/buanet/ioBroker.docker.git
synced 2025-12-17 10:29:00 +02:00
first test of gui for maintenance script
This commit is contained in:
32
debian12/scripts/maintenance_gui.sh
Normal file
32
debian12/scripts/maintenance_gui.sh
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
welcome () {
|
||||||
|
whiptail --title "ioBroker Docker Container Maintenance Script" --ok-button "OK" --msgbox " \
|
||||||
|
╔═══════════════════════════════════════════════════════════════════════╗\
|
||||||
|
\n ║ ██╗ ██████╗ ██████╗ ██████╗ ██████╗ ██╗ ██╗ ███████╗ ██████╗ ║\
|
||||||
|
\n ║ ██║ ██╔═══██╗ ██╔══██╗ ██╔══██╗ ██╔═══██╗ ██║ ██╔╝ ██╔════╝ ██╔══██╗ ║\
|
||||||
|
\n ║ ██║ ██║ ██║ ██████╔╝ ██████╔╝ ██║ ██║ █████╔╝ █████╗ ██████╔╝ ║\
|
||||||
|
\n ║ ██║ ██║ ██║ ██╔══██╗ ██╔══██╗ ██║ ██║ ██╔═██╗ ██╔══╝ ██╔══██╗ ║\
|
||||||
|
\n ║ ██║ ╚██████╔╝ ██████╔╝ ██║ ██║ ╚██████╔╝ ██║ ██╗ ███████╗ ██║ ██║ ║\
|
||||||
|
\n ║ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝ ╚══════╝ ╚═╝ ╚═╝ ║\
|
||||||
|
\n ╚═══════════════════════════════════════════════════════════════════════╝\
|
||||||
|
\n This script will help you to maintain your ioBroker Docker container!\
|
||||||
|
\n" 19 79
|
||||||
|
}
|
||||||
|
|
||||||
|
if welcome; then
|
||||||
|
TO_RUN=$(whiptail --title "ioBroker Docker Container Maintenance Script" --menu "What do you want to do?" 25 78 5 \
|
||||||
|
"maintenance" "Turn Maintenance Mode on or off" \
|
||||||
|
"upgrade" "Upgrade js-controller" \
|
||||||
|
"restore" "Restore ioBroker from backup" 3>&1 1>&2 2>&3)
|
||||||
|
else
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ $TO_RUN = "maintenance" ]]; then
|
||||||
|
echo "You selected maintenance"
|
||||||
|
elif [[ $TO_RUN = "upgrade" ]]; then
|
||||||
|
echo "You selected upgrade"
|
||||||
|
elif [[ $TO_RUN = "restore" ]]; then
|
||||||
|
echo "You selected restore"
|
||||||
|
fi
|
||||||
Reference in New Issue
Block a user