Skip to content

Added basic support for borgbackup

Robin Raymond requested to merge phdoerfler:borgbackup into master

Created by: phdoerfler

Featuring:

  • Another backup solution, yay
  • Support for pushing the backup on a remote server
  • Incremental chunk based backups
  • Easier to move to a different computer than rsync based backups
  • Encryption
  • Selectable encryption method (with hardware acceleration)
  • Automatic handling of passphrase
  • Compression
  • Heuristic for only compressing compressable files
  • Selectable compression method and level
  • Pre exec commands
  • Post exec commands
  • Allows to mount the created backup
  • Integrity checking
  • A systemd service with timer

I have written a nix module encapsulating these things together with a number of checks. My motivation behind this was that I found it awkward to move the backup rsnapshot created to a different computer since there you have different uids, gids, file system features, etc. With borgbackup you don't have this problem. Had I known about borg earlier I would not have created the rsnapshot backup. I put some effort into hiding the password (when encryipting your backups). It is neither stored in /nix/store nor in any other obvious way visible. It gets handed in to borg through an environment variable which is set locally for the borg process using env and read in from a file which one can place in /root for instance.

Merge request reports