Update emulator-sync-scripts.sh

This commit is contained in:
2023-08-12 08:24:45 -05:00
parent a02099ce0e
commit b6abb829ea

View File

@@ -1,6 +1,6 @@
#!/bin/bash
VERS='1.0.5-08112023'
VERS='1.0.7-08122023'
source /opt/idssys/defaults/colors.inc
source /opt/idssys/defaults/default.inc
@@ -50,9 +50,12 @@ RUNSYNC(){
${ES_FOLDER}/nextcloud-sync-cron/nextcloud-sync-cron.sh --verbose --logdir ${ES_LOGFOLDER} ${ES_FOLDER}/nextcloud-client.conf
echo -e "${idsCL[Green]}Done${idsCL[Default]}"
if [ -f ${ES_LOGFOLDER}/failures2.txt ] && [ ! -f ${ES_LOGFOLDER}/failures.txt ]; then
echo "$(date): Fixed" >> ${NC_PATH}/sync.log
echo "$(date): Fixed" >> ${NC_PATH}/sync.log
SENDNOTICE "Nextcloud Sync Fixed" "Sync is running again"
/bin/rm -f ${ES_LOGFOLDER}/failures*
else
echo "Nextcloud 2nd sync failure"
SENDNOTICE "Nextcloud 2nd Sync Failure" "${ES_LOGFOLDER}/failures2.txt Exists\n\n$(date)" 1
fi
/bin/rm -f ${ES_FOLDER}/nc-sync.running
fi