mirror of
https://github.com/raspiblitz/raspiblitz.git
synced 2025-09-29 21:12:39 +02:00
add RTL to Main Menu
This commit is contained in:
@@ -36,14 +36,17 @@ if [ "${rtlWebinterface}" == "on" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Put Activated Apps on top
|
# Put Activated Apps on top
|
||||||
|
if [ "${rtlWebinterface}" == "on" ]; then
|
||||||
|
OPTIONS+=(RTL "RTL Web Node Manager")
|
||||||
|
fi
|
||||||
if [ "${ElectRS}" == "on" ]; then
|
if [ "${ElectRS}" == "on" ]; then
|
||||||
OPTIONS+=(ELECTRS "Electrum Rust Server")
|
OPTIONS+=(ELECTRS "Electrum Rust Server")
|
||||||
fi
|
fi
|
||||||
if [ "${lndmanage}" == "on" ]; then
|
if [ "${lndmanage}" == "on" ]; then
|
||||||
OPTIONS+=(LNDMANAGE "LND Manage Info")
|
OPTIONS+=(LNDMANAGE "LND Manage Script")
|
||||||
fi
|
fi
|
||||||
if [ "${lndmanage}" == "on" ]; then
|
if [ "${lndmanage}" == "on" ]; then
|
||||||
OPTIONS+=(LOOP "Loop In/Out Info")
|
OPTIONS+=(LOOP "Loop In/Out Service")
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Basic Options
|
# Basic Options
|
||||||
@@ -132,6 +135,10 @@ case $CHOICE in
|
|||||||
/home/admin/config.scripts/blitz.touchscreen.sh calibrate
|
/home/admin/config.scripts/blitz.touchscreen.sh calibrate
|
||||||
./00mainMenu.sh
|
./00mainMenu.sh
|
||||||
;;
|
;;
|
||||||
|
RTL)
|
||||||
|
/home/admin/config.scripts/bonus.rtl.sh menu
|
||||||
|
./00mainMenu.sh
|
||||||
|
;;
|
||||||
ELECTRS)
|
ELECTRS)
|
||||||
/home/admin/config.scripts/bonus.electrs.sh menu
|
/home/admin/config.scripts/bonus.electrs.sh menu
|
||||||
./00mainMenu.sh
|
./00mainMenu.sh
|
||||||
|
@@ -322,21 +322,7 @@ if [ "${rtlWebinterface}" != "${choice}" ]; then
|
|||||||
if [ "${choice}" = "on" ]; then
|
if [ "${choice}" = "on" ]; then
|
||||||
if [ ${errorOnInstall} -eq 0 ]; then
|
if [ ${errorOnInstall} -eq 0 ]; then
|
||||||
sudo systemctl start RTL
|
sudo systemctl start RTL
|
||||||
localip=$(ip addr | grep 'state UP' -A2 | tail -n1 | awk '{print $2}' | cut -f1 -d'/')
|
/home/admin/config.scripts/bonus.rtl.sh menu
|
||||||
if [ "${runBehindTor}" = "on" ]; then
|
|
||||||
TOR_ADDRESS=$(sudo cat /mnt/hdd/tor/RTL/hostname)
|
|
||||||
whiptail --title " Installed RTL " --msgbox "\
|
|
||||||
Open the following URL in your local web browser and login with your PASSWORD B.\n
|
|
||||||
---> http://${localip}:3000 \n
|
|
||||||
The Hidden Service address to be used in the Tor Browser is:\n
|
|
||||||
${TOR_ADDRESS}
|
|
||||||
" 14 66
|
|
||||||
else
|
|
||||||
l1="Open the following URL in your local web browser"
|
|
||||||
l2="and login with your PASSWORD B."
|
|
||||||
l3="---> http://${localip}:3000"
|
|
||||||
dialog --title 'OK' --msgbox "${l1}\n${l2}\n${l3}\n${l4}" 7 65
|
|
||||||
fi
|
|
||||||
else
|
else
|
||||||
l1="!!! FAIL on RTL install !!!"
|
l1="!!! FAIL on RTL install !!!"
|
||||||
l2="Try manual install on terminal after reboot with:"
|
l2="Try manual install on terminal after reboot with:"
|
||||||
|
@@ -3,7 +3,7 @@
|
|||||||
# command info
|
# command info
|
||||||
if [ $# -eq 0 ] || [ "$1" = "-h" ] || [ "$1" = "-help" ]; then
|
if [ $# -eq 0 ] || [ "$1" = "-h" ] || [ "$1" = "-help" ]; then
|
||||||
echo "small config script to switch WebGUI RideTheLightning on or off"
|
echo "small config script to switch WebGUI RideTheLightning on or off"
|
||||||
echo "bonus.rtl.sh [on|off]"
|
echo "bonus.rtl.sh [on|off|menu]"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -17,6 +17,23 @@ if [ ${#network} -eq 0 ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# show info menu
|
||||||
|
if [ "$1" = "menu" ]; then
|
||||||
|
localip=$(ip addr | grep 'state UP' -A2 | tail -n1 | awk '{print $2}' | cut -f1 -d'/')
|
||||||
|
torInfo=""
|
||||||
|
toraddress=$(sudo cat /mnt/hdd/tor/RTL/hostname)
|
||||||
|
if [ "${runBehindTor}" = "on" ] && [ ${#toraddress} -gt 0 ]; then
|
||||||
|
torInfo="The Hidden Service address for TOR Browser:\n${toraddress}"
|
||||||
|
fi
|
||||||
|
whiptail --title " Ride The Lightning (RTL)" --msgbox "
|
||||||
|
Open the following URL in your local web browser:
|
||||||
|
http://${localip}:3000
|
||||||
|
Use your Password B to login.\n
|
||||||
|
${toraddress}
|
||||||
|
" 12 56
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
# add default value to raspi config if needed
|
# add default value to raspi config if needed
|
||||||
if ! grep -Eq "^rtlWebinterface=" /mnt/hdd/raspiblitz.conf; then
|
if ! grep -Eq "^rtlWebinterface=" /mnt/hdd/raspiblitz.conf; then
|
||||||
echo "rtlWebinterface=off" >> /mnt/hdd/raspiblitz.conf
|
echo "rtlWebinterface=off" >> /mnt/hdd/raspiblitz.conf
|
||||||
|
Reference in New Issue
Block a user