Being a programmer, I hate to create backups in a drag-and-drop way. Frequently switching Macs and between Fedora and Xubuntu made creating backups and recovery a pain, especially when i wanted only very specific files/directories to be backed up. Backup
is a programmatic way to create and recover backups from location A to location B and back. Locations can be host volumes or external volumes and can be completely controlled by the config backupOptions.json
file.
Run help:
$: python backupCreator.py --help
Run as sudo
for most cases, and pass --create
or -c
:
$: sudo python backupCreator.py --create
# or
$: sudo python backupCreator.py -c
Run as sudo
for most cases, and pass --recover
or -r
:
$: sudo python backupCreator.py --recover
# or
$: sudo python backupCreator.py -r
add
: (List) A list of all dirs and files that need to be backed upignore
: (List) A list of all dirs and files that need to be ignored for backup.storage
: The backup storage volume (eg. and external HDD)destination
: The path where this volume is mounteddir
: A directory on the recovery volume inside which you want the backup to be storedoverwrite_existing
: Set this totrue
if you want any existing backups on the backup volume to be wiped out and overwrittencleanup_copied
: Set this totrue
if you want the files to be removed from your host once the backup copy is complete
recover
: Recover options configdestination
: Base volume where you want the backup to be recovered. Generally your host.owner
: When restored, which user do you want to be the owner (username)? (If you made the backup as root, you might want to get them back to your username upon recovery)group
: When restored, which group do you want to be the owner (group name)? (If you made the backup as root, you might want to get them back to the old group upon recovery)
Here is some sneak peek :)
- Python 2.6+