ShahriyarR / MySQL-AutoXtraBackup

MySQL-AutoXtraBackup commandline tool written in Python 3 based on Percona XtraBackup
https://autoxtrabackup.azepug.az/
MIT License
139 stars 79 forks source link

exclude full directory listing from archive tar.gz #363

Open gitmstoute opened 5 years ago

gitmstoute commented 5 years ago

When I extract a backup from my archive, the result includes the full path to backup_dir where the backup was initially created. In my case: backup_dir = /var/backups/autoxtrabackup/current_backup

The expanded archive includes the /var/backups/... path: ./var/backups/autoxtrabackup/current_backup/

It would be preferable if the archive only included current_backup/ , so it would expand to: ./current_backup/

ShahriyarR commented 5 years ago

Hi, I would like to ask what kind of difficulties this extracting gave you? And also maybe you are interested to send PR for this.

gitmstoute commented 5 years ago

@ShahriyarR for me it was just convenience, if I'm not using autoxtrabackup to do a restore there is less typing. I guess there is also a small risk if a user is at / and extracts an archived backup, it could jumble the contents of the real current_backup.

Yes I'll send a PR when I have time :)