fix
This commit is contained in:
@@ -28,6 +28,7 @@ SSH_KEY="/root/.ssh/id_ed25519"
|
|||||||
logfilename="/tmp/nextcloud-databkp_$(date +"%Y%m%d").log"
|
logfilename="/tmp/nextcloud-databkp_$(date +"%Y%m%d").log"
|
||||||
logNCFilename="nextcloud-data-backup_$(date +"%Y%m%d%H%M")_log.txt"
|
logNCFilename="nextcloud-data-backup_$(date +"%Y%m%d%H%M")_log.txt"
|
||||||
|
|
||||||
|
#copy data
|
||||||
# rsync mit Ausschlussfiltern:
|
# rsync mit Ausschlussfiltern:
|
||||||
# --exclude 'DATEINAME': Verhindert, dass diese Datei kopiert wird
|
# --exclude 'DATEINAME': Verhindert, dass diese Datei kopiert wird
|
||||||
rsync -avzh \
|
rsync -avzh \
|
||||||
@@ -40,7 +41,6 @@ rsync -avzh \
|
|||||||
--exclude 'updater.log.1' \
|
--exclude 'updater.log.1' \
|
||||||
--exclude 'flow.log' \
|
--exclude 'flow.log' \
|
||||||
--exclude 'flow.log.1' \
|
--exclude 'flow.log.1' \
|
||||||
--exclude 'appdata_ocubwyrxncdg' \
|
|
||||||
--progress \
|
--progress \
|
||||||
"$SOURCE_DIR" "$REMOTE_USER@$REMOTE_HOST:$REMOTE_DIR" > $logfilename
|
"$SOURCE_DIR" "$REMOTE_USER@$REMOTE_HOST:$REMOTE_DIR" > $logfilename
|
||||||
|
|
||||||
@@ -50,6 +50,11 @@ if [ $? -eq 0 ]; then
|
|||||||
else
|
else
|
||||||
Mesg="${Mesg}Nextcloud Data rsync failed."
|
Mesg="${Mesg}Nextcloud Data rsync failed."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
#todo Database backup
|
||||||
|
#todo App backup
|
||||||
|
|
||||||
|
|
||||||
MesgID=$(sendMessage2Room $NC_URL $NC_USER $NC_APP_PASSWORD $ROOM_TOKEN "$Mesg")
|
MesgID=$(sendMessage2Room $NC_URL $NC_USER $NC_APP_PASSWORD $ROOM_TOKEN "$Mesg")
|
||||||
sendFile2Room $NC_URL $NC_USER $NC_APP_PASSWORD $ROOM_TOKEN $logfilename $logNCFilename
|
sendFile2Room $NC_URL $NC_USER $NC_APP_PASSWORD $ROOM_TOKEN $logfilename $logNCFilename
|
||||||
rm $logfilename
|
rm $logfilename
|
||||||
|
|||||||
+1
-1
@@ -10,7 +10,7 @@
|
|||||||
|
|
||||||
#this constants is used to control the debug output
|
#this constants is used to control the debug output
|
||||||
#Set libDebug to true to enable debug output, false to disable
|
#Set libDebug to true to enable debug output, false to disable
|
||||||
libDebug=true
|
libDebug=false
|
||||||
|
|
||||||
# logging functions
|
# logging functions
|
||||||
# These functions are used to log messages to the console
|
# These functions are used to log messages to the console
|
||||||
|
|||||||
Reference in New Issue
Block a user