From 7e5d6289a1e689ac5817f6fd0c6069d6e3ba3e31 Mon Sep 17 00:00:00 2001 From: rootzoll Date: Sat, 18 Jul 2020 03:05:08 +0200 Subject: [PATCH] Run BTCPay install in after boot script --- home.admin/_bootstrap.provision.sh | 11 ++++++++--- home.admin/_bootstrap.sh | 3 +++ 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/home.admin/_bootstrap.provision.sh b/home.admin/_bootstrap.provision.sh index 616250b98..86ee9080d 100644 --- a/home.admin/_bootstrap.provision.sh +++ b/home.admin/_bootstrap.provision.sh @@ -286,9 +286,14 @@ fi # BTCPAYSERVER if [ "${BTCPayServer}" = "on" ]; then - echo "Provisioning BTCPAYSERVER on TOR - run config script" >> ${logFile} - sudo sed -i "s/^message=.*/message='Setup BTCPay (takes time)'/g" ${infoFile} - sudo -u admin /home/admin/config.scripts/bonus.btcpayserver.sh on >> ${logFile} 2>&1 + + echo "Provisioning BTCPAYSERVER on TOR - run on after bootup script" >> ${logFile} + #sudo sed -i "s/^message=.*/message='Setup BTCPay (takes time)'/g" ${infoFile} + #sudo -u admin /home/admin/config.scripts/bonus.btcpayserver.sh on >> ${logFile} 2>&1 + + # because BTCPAY server freezes during recovery .. it will get installed after reboot + echo "sudo -u admin /home/admin/config.scripts/bonus.btcpayserver.sh on" >> /home/admin/setup.sh + else echo "Provisioning BTCPayServer - keep default" >> ${logFile} fi diff --git a/home.admin/_bootstrap.sh b/home.admin/_bootstrap.sh index b273054cf..e6f41e17a 100644 --- a/home.admin/_bootstrap.sh +++ b/home.admin/_bootstrap.sh @@ -136,6 +136,9 @@ fi afterSetupScriptExists=$(ls /home/admin/setup.sh 2>/dev/null | grep -c setup.sh) if [ ${afterSetupScriptExists} -eq 1 ]; then echo "*** SETUP SCRIPT DETECTED ***" + # LCD info + sudo sed -i "s/^state=.*/state=recovering/g" ${infoFile} + sudo sed -i "s/^message=.*/message='After Boot Setup (takes time)'/g" ${infoFile} # echo out script to journal logs sudo cat /home/admin/setup.sh # execute the after boot script