Operating system: Ubuntu
OS version: 20.04
Hello, i want to run command after backup that processes the files in backup destination.
In the help for “Command to run after backup” i see there is environment variable BACKUP_DEST: The destination directory or URL.
My backup destination is /backups/%Y-%m-%d with strftime substitution and when i print BACKUP_DEST at end of backup it displays /backups/%Y-%m-%d instead of /backups/2021-04-15 as it is on the filesystem.
How can i obtain the proper path to the backup files after it completes?
Another question:
I am using this command to run before backups: export BACKUP_DATE=date +"%Y-%m-%d"
;
And then command to run after backups: echo $BACKUP_DATE ; → prints nothing.
Why it’s not keeping the environment variable between before and after commands ?
Any suggestions to get the backup location path after backup complete?