mirror of
https://github.com/raspiblitz/raspiblitz.git
synced 2025-09-28 04:26:28 +02:00
committed by
rootzoll
parent
99a652f3cf
commit
654aa290e4
@@ -107,6 +107,9 @@ fi
|
|||||||
if [ "${zerotier}" == "on" ]; then
|
if [ "${zerotier}" == "on" ]; then
|
||||||
OPTIONS+=(ZEROTIER "ZeroTier")
|
OPTIONS+=(ZEROTIER "ZeroTier")
|
||||||
fi
|
fi
|
||||||
|
if [ "${pool}" == "on" ]; then
|
||||||
|
OPTIONS+=(POOL "Lightning Pool")
|
||||||
|
fi
|
||||||
|
|
||||||
# Basic Options
|
# Basic Options
|
||||||
OPTIONS+=(INFO "RaspiBlitz Status Screen")
|
OPTIONS+=(INFO "RaspiBlitz Status Screen")
|
||||||
@@ -234,7 +237,7 @@ case $CHOICE in
|
|||||||
BOS)
|
BOS)
|
||||||
sudo /home/admin/config.scripts/bonus.bos.sh menu
|
sudo /home/admin/config.scripts/bonus.bos.sh menu
|
||||||
;;
|
;;
|
||||||
PYBLOCK)
|
PYBLOCK)
|
||||||
sudo /home/admin/config.scripts/bonus.pyblock.sh menu
|
sudo /home/admin/config.scripts/bonus.pyblock.sh menu
|
||||||
;;
|
;;
|
||||||
THUB)
|
THUB)
|
||||||
@@ -243,6 +246,9 @@ case $CHOICE in
|
|||||||
ZEROTIER)
|
ZEROTIER)
|
||||||
sudo /home/admin/config.scripts/bonus.zerotier.sh menu
|
sudo /home/admin/config.scripts/bonus.zerotier.sh menu
|
||||||
;;
|
;;
|
||||||
|
POOL)
|
||||||
|
sudo /home/admin/config.scripts/bonus.pool.sh menu
|
||||||
|
;;
|
||||||
SUBSCRIBE)
|
SUBSCRIBE)
|
||||||
/home/admin/config.scripts/blitz.subscriptions.py
|
/home/admin/config.scripts/blitz.subscriptions.py
|
||||||
;;
|
;;
|
||||||
|
@@ -20,6 +20,7 @@ if [ ${#faraday} -eq 0 ]; then faraday="off"; fi
|
|||||||
if [ ${#bos} -eq 0 ]; then bos="off"; fi
|
if [ ${#bos} -eq 0 ]; then bos="off"; fi
|
||||||
if [ ${#pyblock} -eq 0 ]; then pyblock="off"; fi
|
if [ ${#pyblock} -eq 0 ]; then pyblock="off"; fi
|
||||||
if [ ${#thunderhub} -eq 0 ]; then thunderhub="off"; fi
|
if [ ${#thunderhub} -eq 0 ]; then thunderhub="off"; fi
|
||||||
|
if [ ${#pool} -eq 0 ]; then pool="off"; fi
|
||||||
|
|
||||||
# show select dialog
|
# show select dialog
|
||||||
echo "run dialog ..."
|
echo "run dialog ..."
|
||||||
@@ -39,6 +40,7 @@ OPTIONS+=(o 'Balance of Satoshis' ${bos})
|
|||||||
OPTIONS+=(y 'PyBLOCK' ${pyblock})
|
OPTIONS+=(y 'PyBLOCK' ${pyblock})
|
||||||
OPTIONS+=(f 'Faraday' ${faraday})
|
OPTIONS+=(f 'Faraday' ${faraday})
|
||||||
OPTIONS+=(m 'lndmanage' ${lndmanage})
|
OPTIONS+=(m 'lndmanage' ${lndmanage})
|
||||||
|
OPTIONS+=(c 'Lightning Pool' ${pool})
|
||||||
|
|
||||||
CHOICES=$(dialog --title ' Additional Services ' --checklist ' use spacebar to activate/de-activate ' 20 45 12 "${OPTIONS[@]}" 2>&1 >/dev/tty)
|
CHOICES=$(dialog --title ' Additional Services ' --checklist ' use spacebar to activate/de-activate ' 20 45 12 "${OPTIONS[@]}" 2>&1 >/dev/tty)
|
||||||
|
|
||||||
@@ -347,6 +349,20 @@ else
|
|||||||
echo "LNbits setting unchanged."
|
echo "LNbits setting unchanged."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Lightning Pool
|
||||||
|
choice="off"; check=$(echo "${CHOICES}" | grep -c "c")
|
||||||
|
if [ ${check} -eq 1 ]; then choice="on"; fi
|
||||||
|
if [ "${pool}" != "${choice}" ]; then
|
||||||
|
echo "Pool Setting changed .."
|
||||||
|
anychange=1
|
||||||
|
sudo -u admin /home/admin/config.scripts/bonus.pool.sh ${choice}
|
||||||
|
if [ "${choice}" = "on" ]; then
|
||||||
|
sudo -u admin /home/admin/config.scripts/bonus.pool.sh menu
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
echo "Pool setting unchanged."
|
||||||
|
fi
|
||||||
|
|
||||||
# JoinMarket process choice
|
# JoinMarket process choice
|
||||||
choice="off"; check=$(echo "${CHOICES}" | grep -c "j")
|
choice="off"; check=$(echo "${CHOICES}" | grep -c "j")
|
||||||
if [ ${check} -eq 1 ]; then choice="on"; fi
|
if [ ${check} -eq 1 ]; then choice="on"; fi
|
||||||
|
@@ -519,6 +519,15 @@ else
|
|||||||
echo "Provisioning Stacking Sats Kraken - keep default" >> ${logFile}
|
echo "Provisioning Stacking Sats Kraken - keep default" >> ${logFile}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# pool
|
||||||
|
if [ "${pool}" = "on" ]; then
|
||||||
|
echo "Provisioning Pool - run config script" >> ${logFile}
|
||||||
|
sudo sed -i "s/^message=.*/message='Setup Pool'/g" ${infoFile}
|
||||||
|
sudo -u admin /home/admin/config.scripts/bonus.pool.sh on >> ${logFile} 2>&1
|
||||||
|
else
|
||||||
|
echo "Provisioning Pool - keep default" >> ${logFile}
|
||||||
|
fi
|
||||||
|
|
||||||
# custom install script from user
|
# custom install script from user
|
||||||
customInstallAvailable=$(sudo ls /mnt/hdd/app-data/custom-installs.sh 2>/dev/null | grep -c "custom-installs.sh")
|
customInstallAvailable=$(sudo ls /mnt/hdd/app-data/custom-installs.sh 2>/dev/null | grep -c "custom-installs.sh")
|
||||||
if [ ${customInstallAvailable} -gt 0 ]; then
|
if [ ${customInstallAvailable} -gt 0 ]; then
|
||||||
|
@@ -147,6 +147,7 @@ function jm() {
|
|||||||
if [ $(grep -c "joinmarket=on" < /mnt/hdd/raspiblitz.conf) -eq 1 ]; then
|
if [ $(grep -c "joinmarket=on" < /mnt/hdd/raspiblitz.conf) -eq 1 ]; then
|
||||||
echo "# switching to the joinmarket user with the command: 'sudo su - joinmarket'"
|
echo "# switching to the joinmarket user with the command: 'sudo su - joinmarket'"
|
||||||
sudo su - joinmarket
|
sudo su - joinmarket
|
||||||
|
echo "# use command 'raspiblitz' to return to menu"
|
||||||
else
|
else
|
||||||
echo "JoinMarket is not installed - to install run:"
|
echo "JoinMarket is not installed - to install run:"
|
||||||
echo "sudo /home/admin/config.scripts/bonus.joinmarket.sh on"
|
echo "sudo /home/admin/config.scripts/bonus.joinmarket.sh on"
|
||||||
@@ -158,8 +159,8 @@ function jm() {
|
|||||||
function faraday() {
|
function faraday() {
|
||||||
if [ $(grep -c "faraday=on" < /mnt/hdd/raspiblitz.conf) -eq 1 ]; then
|
if [ $(grep -c "faraday=on" < /mnt/hdd/raspiblitz.conf) -eq 1 ]; then
|
||||||
echo "# switching to the faraday user with the command: 'sudo su - faraday'"
|
echo "# switching to the faraday user with the command: 'sudo su - faraday'"
|
||||||
echo "# when done use command 'exit' to return to admin user"
|
echo "# use command 'exit' and then 'raspiblitz' to return to menu"
|
||||||
echo "# see faraday options with --> frcli -help"
|
echo "# use command 'frcli --help' now to get more info"
|
||||||
sudo su - faraday
|
sudo su - faraday
|
||||||
else
|
else
|
||||||
echo "Faraday is not installed - to install run:"
|
echo "Faraday is not installed - to install run:"
|
||||||
@@ -172,6 +173,8 @@ function faraday() {
|
|||||||
function loop() {
|
function loop() {
|
||||||
if [ $(grep -c "loop=on" < /mnt/hdd/raspiblitz.conf) -eq 1 ]; then
|
if [ $(grep -c "loop=on" < /mnt/hdd/raspiblitz.conf) -eq 1 ]; then
|
||||||
echo "# switching to the loop user with the command: 'sudo su - loop'"
|
echo "# switching to the loop user with the command: 'sudo su - loop'"
|
||||||
|
echo "# use command 'exit' and then 'raspiblitz' to return to menu"
|
||||||
|
echo "# use command 'loop --help' now to get more info"
|
||||||
sudo su - loop
|
sudo su - loop
|
||||||
else
|
else
|
||||||
echo "Lightning Loop is not installed - to install run:"
|
echo "Lightning Loop is not installed - to install run:"
|
||||||
@@ -184,6 +187,8 @@ function loop() {
|
|||||||
function pool() {
|
function pool() {
|
||||||
if [ $(grep -c "pool=on" < /mnt/hdd/raspiblitz.conf) -gt 0 ]; then
|
if [ $(grep -c "pool=on" < /mnt/hdd/raspiblitz.conf) -gt 0 ]; then
|
||||||
echo "# switching to the pool user with the command: 'sudo su - pool'"
|
echo "# switching to the pool user with the command: 'sudo su - pool'"
|
||||||
|
echo "# use command 'exit' and then 'raspiblitz' to return to menu"
|
||||||
|
echo "# use command 'pool --help' now to get more info"
|
||||||
sudo su - pool
|
sudo su - pool
|
||||||
else
|
else
|
||||||
echo "Pool is not installed - to install run:"
|
echo "Pool is not installed - to install run:"
|
||||||
|
@@ -20,11 +20,10 @@ fi
|
|||||||
|
|
||||||
# show info menu
|
# show info menu
|
||||||
if [ "$1" = "menu" ]; then
|
if [ "$1" = "menu" ]; then
|
||||||
dialog --title " Info Pool Service " --msgbox "\n\
|
whiptail --title " Info Pool Service " --msgbox "\
|
||||||
Usage and examples: https://github.com/lightninglabs/pool\n
|
Usage and examples: https://github.com/lightninglabs/pool\n
|
||||||
Use the shortcut 'pool' in the terminal to switch to the dedicated user.\n
|
Use the shortcut 'pool' in the terminal to switch to the dedicated user and type 'pool' again to see the options.
|
||||||
Type 'pool' again to see the options.
|
" 12 56
|
||||||
" 11 56
|
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user