Update defaults.inc
This commit is contained in:
11
defaults.inc
11
defaults.inc
@@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
VERS='2.7.122b-11092024'
|
||||
VERS='2.7.123-11092024'
|
||||
|
||||
noheader=' update service dailytemp confsync -r -report test '
|
||||
|
||||
@@ -57,7 +57,10 @@ PW_ESXI_FANSPEEDCONTROLHOSTS=(${PW_ESXI_FANSPEEDCONTROL_HOSTS})
|
||||
[ "${PW_TEMPIND_RANGE}" != "" ] && PW_TEMPIND_RANGE=(${PW_TEMPIND_RANGE})
|
||||
unset IFS
|
||||
|
||||
if [ -f ${PW_FOLDER}/conf/settings.local.conf ]; then
|
||||
IP=$(ip addr show $(ip route | awk '/default/ { print $5 }') | grep "inet" | head -n 1 | awk '/inet/ {print $2}' | cut -d'/' -f1)
|
||||
[[ "${IP}" = "10.2.1."* ]] && loo=offsite || loo=local
|
||||
|
||||
if [ -f ${PW_FOLDER}/conf/settings.${loo}.conf ]; then
|
||||
declare -A PW_POWERWALL_SERVICES
|
||||
declare -A PW_THRESHOLDS
|
||||
declare -A PW_SENSOR_TYPE
|
||||
@@ -78,12 +81,12 @@ if [ -f ${PW_FOLDER}/conf/settings.local.conf ]; then
|
||||
declare -A PW_MISCSENSOR_DESC
|
||||
declare -A PW_DESC_TEMP
|
||||
|
||||
source ${PW_FOLDER}/conf/settings.local.conf
|
||||
source ${PW_FOLDER}/conf/settings.${loo}.conf
|
||||
|
||||
[ "${PW_TEMPIND_DIFF}" == "" ] && PW_TEMPIND_DIFF=1
|
||||
|
||||
else
|
||||
echo "NO settings.local.conf FILE FOUND"
|
||||
echo "NO settings.${loo}.conf FILE FOUND"
|
||||
[ "${1}" ] && [ "${1}" != "update" ] && exit 1
|
||||
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user