move prepare config into ON

This commit is contained in:
rootzoll 2021-09-01 00:57:22 +02:00
parent bd419743ed
commit ba8f869187

View File

@ -113,15 +113,6 @@ Activate TOR to access the web interface from outside your local network.
exit 0
fi
# prepare raspiblitz.conf --> add default value
configEntryExists=$(sudo cat /mnt/hdd/raspiblitz.conf | grep -c "${configEntry}")
if [ "${configEntryExists}" == "0" ]; then
echo "# adding default config entry for '${configEntry}'"
sudo /bin/sh -c "echo '${configEntry}=off' >> /mnt/hdd/raspiblitz.conf"
else
echo "# default config entry for '${configEntry}' exists"
fi
##########################
# ON
#########################
@ -143,6 +134,15 @@ if [ "$1" = "1" ] || [ "$1" = "on" ]; then
echo "# Installing RTL for ${LNTYPE} ${CHAIN}"
# prepare raspiblitz.conf --> add default value
configEntryExists=$(sudo cat /mnt/hdd/raspiblitz.conf | grep -c "${configEntry}")
if [ "${configEntryExists}" == "0" ]; then
echo "# adding default config entry for '${configEntry}'"
sudo /bin/sh -c "echo '${configEntry}=off' >> /mnt/hdd/raspiblitz.conf"
else
echo "# default config entry for '${configEntry}' exists"
fi
# check and install NodeJS
/home/admin/config.scripts/bonus.nodejs.sh on