mirror of
https://github.com/raspiblitz/raspiblitz.git
synced 2025-11-18 18:07:45 +01:00
clean scripts
This commit is contained in:
@@ -87,4 +87,4 @@ sudo apt-get update
|
|||||||
echo "OK - System is now up to date"
|
echo "OK - System is now up to date"
|
||||||
|
|
||||||
# mark setup is done
|
# mark setup is done
|
||||||
sudo sed -i "s/^setupStep=.*/setupStep=100/g" /home/admin/raspiblitz.info
|
sudo sed -i "s/^setupStep=.*/setupStep=90/g" /home/admin/raspiblitz.info
|
||||||
@@ -29,7 +29,7 @@ cp $logFile /home/admin/raspiblitz.setup.log
|
|||||||
echo "Setting the Name/Alias/Hostname .."
|
echo "Setting the Name/Alias/Hostname .."
|
||||||
sudo /home/admin/config.scripts/lnd.setname.sh ${hostname}
|
sudo /home/admin/config.scripts/lnd.setname.sh ${hostname}
|
||||||
|
|
||||||
# mark setup is done
|
# mark setup is done (100%)
|
||||||
sudo sed -i "s/^setupStep=.*/setupStep=100/g" /home/admin/raspiblitz.info
|
sudo sed -i "s/^setupStep=.*/setupStep=100/g" /home/admin/raspiblitz.info
|
||||||
|
|
||||||
clear
|
clear
|
||||||
|
|||||||
@@ -64,9 +64,7 @@ else
|
|||||||
sudo rm -f -r /mnt/hdd/tor
|
sudo rm -f -r /mnt/hdd/tor
|
||||||
sudo rm -f /mnt/hdd/raspiblitz.conf
|
sudo rm -f /mnt/hdd/raspiblitz.conf
|
||||||
sudo rm -f /home/admin/raspiblitz.info
|
sudo rm -f /home/admin/raspiblitz.info
|
||||||
# recreate /mnt/hdd/ssh otherwise link with /etc/ssh is broken
|
|
||||||
sudo mkdir /mnt/hdd/ssh
|
|
||||||
|
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|||||||
@@ -53,9 +53,7 @@ echo "message=" >> $infoFile
|
|||||||
echo "network=${network}" >> $infoFile
|
echo "network=${network}" >> $infoFile
|
||||||
echo "chain=${chain}" >> $infoFile
|
echo "chain=${chain}" >> $infoFile
|
||||||
echo "setupStep=${setupStep}" >> $infoFile
|
echo "setupStep=${setupStep}" >> $infoFile
|
||||||
if [ "${setupStep}" != "100" ]; then
|
echo "hostname=${hostname}" >> $infoFile
|
||||||
echo "hostname=${hostname}" >> $infoFile
|
|
||||||
fi
|
|
||||||
sudo chmod 777 ${infoFile}
|
sudo chmod 777 ${infoFile}
|
||||||
|
|
||||||
################################
|
################################
|
||||||
@@ -227,9 +225,8 @@ if [ ${hddIsAutoMounted} -eq 0 ]; then
|
|||||||
|
|
||||||
# check if HDD contains pre-loaded blockchain data
|
# check if HDD contains pre-loaded blockchain data
|
||||||
echo "Check if HDD contains pre-loaded blockchain data .." >> $logFile
|
echo "Check if HDD contains pre-loaded blockchain data .." >> $logFile
|
||||||
# setup running with admin user, but has no permission to read /mnt/hdd/bitcoin/blocks/, sudo needed
|
litecoinDataExists=$(ls /mnt/hdd/litecoin/blocks/blk00000.dat 2>/dev/null | grep -c '.dat')
|
||||||
litecoinDataExists=$(sudo ls /mnt/hdd/litecoin/blocks/blk00000.dat 2>/dev/null | grep -c '.dat')
|
bitcoinDataExists=$(ls /mnt/hdd/bitcoin/blocks/blk00000.dat 2>/dev/null | grep -c '.dat')
|
||||||
bitcoinDataExists=$(sudo ls /mnt/hdd/bitcoin/blocks/blk00000.dat 2>/dev/null | grep -c '.dat')
|
|
||||||
|
|
||||||
# check if node can go into presync (only for bitcoin)
|
# check if node can go into presync (only for bitcoin)
|
||||||
if [ ${bitcoinDataExists} -eq 1 ]; then
|
if [ ${bitcoinDataExists} -eq 1 ]; then
|
||||||
|
|||||||
@@ -14,4 +14,4 @@ ExecStart=/home/admin/_bootstrap.sh
|
|||||||
StandardOutput=journal
|
StandardOutput=journal
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
@@ -22,4 +22,4 @@ Restart=always
|
|||||||
RestartSec=60
|
RestartSec=60
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
Reference in New Issue
Block a user