#1116 make sure matching loop version is installed

This commit is contained in:
rootzoll 2020-05-01 18:20:47 +02:00
parent 1a78b28243
commit c26a5f7393
2 changed files with 15 additions and 1 deletions

View file

@ -208,11 +208,20 @@ Do you really want to update LND now?
echo "# cancel update"
exit 1
fi
# if loop is installed remove
if [ "${loop}" == "on" ]; then
sudo -u admin /home/admin/config.scripts/bonus.loop.sh on
fi
error=""
warn=""
source <(sudo -u admin /home/admin/config.scripts/lnd.update.sh verified)
if [ ${#error} -gt 0 ]; then
whiptail --title "ERROR" --msgbox "${error}" 8 30
else
# if loop was installed before reinstall
if [ "${loop}" == "on" ]; then
sudo -u admin /home/admin/config.scripts/bonus.loop.sh on
fi
/home/admin/XXshutdown.sh reboot
sleep 8
fi

View file

@ -42,7 +42,12 @@ if [ "$1" = "1" ] || [ "$1" = "on" ]; then
sudo -u bitcoin git clone https://github.com/lightninglabs/loop.git
cd /home/bitcoin/loop
# https://github.com/lightninglabs/loop/releases
sudo -u bitcoin git reset --hard v0.5.1-beta
source <(sudo -u admin /home/admin/config.scripts/lnd.update.sh info)
if [ ${lndInstalledVersionMain} -lt 10 ]; then
sudo -u bitcoin git reset --hard v0.5.1-beta
else
sudo -u bitcoin git reset --hard v0.6.0-beta
fi
cd /home/bitcoin/loop/cmd
go install ./...