1
0
mirror of https://github.com/deajan/obackup.git synced 2024-11-14 19:53:42 +01:00

Rebuilt targets

This commit is contained in:
deajan 2018-09-30 17:18:09 +02:00
parent ee52fe13a9
commit 512bf8e5a4
2 changed files with 18 additions and 8 deletions

View File

@ -7,7 +7,7 @@ PROGRAM="obackup"
AUTHOR="(C) 2013-2018 by Orsiris de Jong"
CONTACT="http://www.netpower.fr/obackup - ozy@netpower.fr"
PROGRAM_VERSION=2.1-RC1
PROGRAM_BUILD=2018093006
PROGRAM_BUILD=2018093008
IS_STABLE=no
#### Execution order #__WITH_PARANOIA_DEBUG
@ -4544,6 +4544,11 @@ function RemoteLogger {
}
function _RotateBackupsRemoteSSH {
local backup
local copy
local cmd
local path
$REMOTE_FIND_CMD "$backupPath" -mindepth 1 -maxdepth 1 ! -regex ".*\.$PROGRAM\.[0-9]+" -print0 | while IFS= read -r -d $'\0' backup; do
copy=$rotateCopies
while [ $copy -gt 1 ]; do
@ -4570,7 +4575,7 @@ function _RotateBackupsRemoteSSH {
fi
fi
copy=$((opy-1))
copy=$((copy-1))
done
# Latest file backup will not be moved if script configured for remote backup so next rsync execution will only do delta copy instead of full one
@ -4628,11 +4633,11 @@ function RotateBackups {
__CheckArguments 2 $# "$@" #__WITH_PARANOIA_DEBUG
Logger "Rotating backups in [$backupPath] for [$rotateCopies] copies." "NOTICE"
if [ "$BACKUP_TYPE" == "local" ] || [ "$BACKUP_TYPE" == "pull" ]; then
Logger "Rotating local backups in [$backupPath] for [$rotateCopies] copies." "NOTICE"
_RotateBackupsLocal "$backupPath" "$rotateCopies"
elif [ "$BACKUP_TYPE" == "push" ]; then
Logger "Rotating remote backups in [$backupPath] for [$rotateCopies] copies." "NOTICE"
_RotateBackupsRemote "$backupPath" "$rotateCopies"
fi
}

View File

@ -7,7 +7,7 @@ PROGRAM="obackup"
AUTHOR="(C) 2013-2018 by Orsiris de Jong"
CONTACT="http://www.netpower.fr/obackup - ozy@netpower.fr"
PROGRAM_VERSION=2.1-RC1
PROGRAM_BUILD=2018093006
PROGRAM_BUILD=2018093008
IS_STABLE=no
@ -4324,6 +4324,11 @@ function RemoteLogger {
}
function _RotateBackupsRemoteSSH {
local backup
local copy
local cmd
local path
$REMOTE_FIND_CMD "$backupPath" -mindepth 1 -maxdepth 1 ! -regex ".*\.$PROGRAM\.[0-9]+" -print0 | while IFS= read -r -d $'\0' backup; do
copy=$rotateCopies
while [ $copy -gt 1 ]; do
@ -4350,7 +4355,7 @@ function _RotateBackupsRemoteSSH {
fi
fi
copy=$((opy-1))
copy=$((copy-1))
done
# Latest file backup will not be moved if script configured for remote backup so next rsync execution will only do delta copy instead of full one
@ -4407,11 +4412,11 @@ function RotateBackups {
local rotateCopies="${2}"
Logger "Rotating backups in [$backupPath] for [$rotateCopies] copies." "NOTICE"
if [ "$BACKUP_TYPE" == "local" ] || [ "$BACKUP_TYPE" == "pull" ]; then
Logger "Rotating local backups in [$backupPath] for [$rotateCopies] copies." "NOTICE"
_RotateBackupsLocal "$backupPath" "$rotateCopies"
elif [ "$BACKUP_TYPE" == "push" ]; then
Logger "Rotating remote backups in [$backupPath] for [$rotateCopies] copies." "NOTICE"
_RotateBackupsRemote "$backupPath" "$rotateCopies"
fi
}