This commit is contained in:
2024-12-01 18:05:05 -06:00
parent 753e1a6a7d
commit ce2c2f7213
3 changed files with 12 additions and 7 deletions

View File

@@ -744,16 +744,18 @@ GET_SNAPSHOTS(){
CONFSYNC(){
[ "${PW_OFFSITE_MONITOR}" != "" ] && rsync -az --timeout=3 ${PW_FOLDER}/conf root@${PW_OFFSITE_MONITOR}:${PW_FOLDER}/ & >/dev/null 2>&1
if [ -f /opt/idssys/nodemgmt/conf/defaults.local.inc ]; then
source /opt/idssys/nodemgmt/defaults.inc
rsync -az --timeout=3 ${PW_FOLDER}/conf/* root@${NM_NODEMANAGER}:/opt/idssys/nodemgmt/conf/powerwall/ & >/dev/null 2>&1
# rsync -az --timeout=3 ${PW_FOLDER}/conf/settings.ps1 root@${NM_NODEMANAGER}:/opt/idssys/nodemgmt/conf/powerwall.settings.ps1 & >/dev/null 2>&1
if [ -f ${NM_FOLDER}/conf/defaults.local.inc ]; then
source ${NM_FOLDER}/defaults.inc
rsync -az --timeout=3 ${PW_FOLDER}/conf/* root@${NM_NODEMANAGER}:${NM_FOLDER}/conf/powerwall/ & >/dev/null 2>&1
# rsync -az --timeout=3 ${PW_FOLDER}/conf/settings.ps1 root@${NM_NODEMANAGER}:${NM_FOLDER}/conf/powerwall.settings.ps1 & >/dev/null 2>&1
else
fi
}
UPDATE_TINYTUYA_SERVER(){
TTS_FLDR=/opt/tinytuya-server
if [ ! -f /opt/raspiBackup.running ]; then
if [ ! -f /opt/raspiBackup.running ] && ([ -f ${NM_TMPFOLDER}/.singleserver.PW2.primary ] || [ -f ${NM_TMPFOLDER}/.singleserver.PWO2.primary ]); then
if [ -d ${TTS_FLDR}/devices.json ]; then
docker stop tinytuya-server
rm -Rf ${TTS_FLDR}/devices.json