Yep sorry for the late response. That is the primary use case. Thanks for the consideration. I might even try my hand at it if I get some free time the weekend. Though I doubt it I've got a huge project at work right now.
1 year ago
Separate configurations could work. I just tend to prefer to keep a single config. But I can live with that. Kicking off separate instances was basically what I was thinking. The main reason being to reduce the amount of time it takes to backup the entire folder when each snapshot should be a single self contained entity. It would also make it much easier to restore since I could just restore a single snapshot by restoring a backup rather than having to mount a backup or restore a folder from within the backup. I would just make a separate config for each subfolder but with the way snapper and from what I can tell other snapshotting software name their folders that wouldn't really be possible since you can't really predict how many folders there will be and what their names will be. It seems like this could be achieved with a for loop that just waits for each instance to finish before kicking off another. The boolean was to specify whether you want the backup to be the source directory or if you want it to be the sub directories. Maybe I am just thinking about this wrong but that just seems like the best way to deal with rolling snapshots and borg. If I'm not mistaken if it was setup this way I would be able to set borg's and snapper's pruning to be exactly the same and then my backups would basically mirror the structure of my snapshot folder. I understand if you think this is outside the scope of this script I just thought it would be quite useful for anyone out there wanting to run borg with automated snapshotting. Hopefully I clarified my request it's been a long day so sorry if it's confusing.
1 year ago