remove wait for sync from setup

This commit is contained in:
rootzoll
2018-12-10 17:55:58 +01:00
parent 52892c30d4
commit d7aa6b5d6b

View File

@@ -206,39 +206,39 @@ else
echo "OK - Wallet is already unlocked" echo "OK - Wallet is already unlocked"
fi fi
### Show Lighthning Sync #### Show Lighthning Sync
echo "" #echo ""
echo "*** Check LND Sync ***" #echo "*** Check LND Sync ***"
item=0 #item=0
lndSyncing=$(sudo -u bitcoin /usr/local/bin/lncli --chain=${network} getinfo 2>/dev/null | jq -r '.synced_to_chain' | grep -c true) #lndSyncing=$(sudo -u bitcoin /usr/local/bin/lncli --chain=${network} getinfo 2>/dev/null | jq -r '.synced_to_chain' | grep -c true)
if [ ${lndSyncing} -eq 0 ]; then #if [ ${lndSyncing} -eq 0 ]; then
echo "OK - wait for LND to be synced" # echo "OK - wait for LND to be synced"
while : # while :
do # do
#
# show sync status # # show sync status
./80scanLND.sh # ./80scanLND.sh
sleep 15 # sleep 15
#
# break loop when synced # # break loop when synced
lndSyncing=$(sudo -u bitcoin /usr/local/bin/lncli --chain=${network} getinfo 2>/dev/null | jq -r '.synced_to_chain' | grep -c true) # lndSyncing=$(sudo -u bitcoin /usr/local/bin/lncli --chain=${network} getinfo 2>/dev/null | jq -r '.synced_to_chain' | grep -c true)
if [ ${lndSyncing} -eq 1 ]; then # if [ ${lndSyncing} -eq 1 ]; then
break # break
fi # fi
#
# break loop when wallet is locked # # break loop when wallet is locked
locked=$(sudo tail -n 1 /mnt/hdd/lnd/logs/${network}/${chain}net/lnd.log | grep -c unlock) # locked=$(sudo tail -n 1 /mnt/hdd/lnd/logs/${network}/${chain}net/lnd.log | grep -c unlock)
if [ ${locked} -eq 1 ]; then # if [ ${locked} -eq 1 ]; then
break # break
fi # fi
#
sleep 15 # sleep 15
#
done # done
clear # clear
else #else
echo "OK - LND is in sync" # echo "OK - LND is in sync"
fi #fi
# set SetupState (scan is done - so its 80%) # set SetupState (scan is done - so its 80%)
sudo sed -i "s/^setupStep=.*/setupStep=80/g" /home/admin/raspiblitz.info sudo sed -i "s/^setupStep=.*/setupStep=80/g" /home/admin/raspiblitz.info