mirror of
https://github.com/myvesta/vesta
synced 2025-08-14 18:49:21 -07:00
Backup filename changed (#1289)
* Backup filename changed Changed the backup filename for running more backup each day - for example every 4 hours * Restore user fix with new backup date * Check if the backup name has an old notation * Fix backup permission check * fixed regex * fix
This commit is contained in:
parent
fc60a99e8c
commit
f8368220ff
2 changed files with 39 additions and 31 deletions
|
@ -38,8 +38,15 @@ source $VESTA/conf/vesta.conf
|
|||
|
||||
# Check backup ownership function
|
||||
is_backup_available() {
|
||||
if ! [[ $2 =~ ^$1.[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9].tar$ ]]; then
|
||||
check_result $E_FORBIDEN "permission denied"
|
||||
passed=false
|
||||
if [[ $2 =~ ^$1.[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]_[0-9][0-9]-[0-9][0-9]-[0-9][0-9].tar$ ]]; then
|
||||
passed=true
|
||||
elif [[ $2 =~ ^$1.[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9].tar$ ]]; then
|
||||
passed=true
|
||||
fi
|
||||
|
||||
if [ $passed = false ]; then
|
||||
check_result $E_FORBIDEN "permission denied"
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue