xibodevelopment / backupwordpress

Simple automated backups of your WordPress powered website.
http://wordpress.org/extend/plugins/backupwordpress/
327 stars 74 forks source link

Ability to backup multiple directories #574

Open joehoyle opened 10 years ago

joehoyle commented 10 years ago

Currently you can only select one directory for BackUpWordPress to backup, this is typically the root of your wordpress site. However, in the event of you uploads / any other custom directories being stored outside your site's root they won't be backed up.

One work-around would be to symlink them into your web root, but that would potentially do away with the security reason why you had that initial directory outside of your web root.

It would be good if you could pass multiple additional paths to also be backed up. I think you'd want to keep it as "additional" as each extra DIR would need to be placed in a subdir of your root directory in the backup archive. Either that of the "default" web root backup directory would be mapped to be placed in the relative "root" in the zip archive. For example:

array(
    '/srv/www/webroot/' => '/',
    '/var/log/php/' => '/php-logs',
    's3://hmn-uploads/hmn/' => '/uploads'
);

In this example I am using a StreamWrapper to map to S3, given I am using the S3-Uploads plugin, BackUpWordPress will be able to use this method fine as long as it uses PCLZIP or ZipArchive. I believe that fallback would automatically be handled in hm-backup.

I'm not sure if this would be a hm-backup addition or backupwordpress, it seems it might be good if hm-backup would support being passed an existing archive, in which case it would be called x amount of times from BackUpWordPress for each distinct directory it is backing up.

owaincuvelier commented 10 years ago

BackUpWordPress will be able to use this method fine as long as it uses PCLZIP or ZipArchive.

Does that mean it can't use it with the ZIP command?

joehoyle commented 10 years ago

Does that mean it can't use it with the ZIP command?

For the general case of backing up multiple directories the ZIP command would be fine, it's only for the more special case of s3:// that would need to use PHP.

The two wouldn't need to be developed together, was just a use case for when you'd want to backup multiple directories.

willmot commented 8 years ago

This is much more possible now we have Finder.

libby-barker commented 7 years ago

@joehoyle wondering if you might be able to reply with some specific tasks associated with your note above so I can scope out more fully?

joehoyle commented 7 years ago

@libby-barker hmm I'm no sure I'm the best one, as I don't really know anything about the new Finder stuff.