pub / rsync_encrypted_backup

Encrypted backups based on gocryptfs and rsync
git clone https://src.jayvii.de/pub/rsync_encrypted_backup.git
Home | Log | Files | Exports | Refs | README | RSS

README.md (1299B)


      1 # Encrypted Backup via rsync and gocryptfs
      2 
      3 Please send patches or remarks to
      4 [jayvii[AT]posteo[DOT]de](mailto:jayvii[AT]posteo[DOT]de)
      5 
      6 Atomic and encrypted backups made easy with a simple bash script.
      7 
      8 Detailed description can be found
      9 [on my blog](https://www.jayvii.de/posts/backups/)
     10 
     11 Uses well-known tools, following the UNIX-philosophy:
     12 
     13 * [rsnc](https://rsync.samba.org/)
     14 * [gocryptfs](https://nuetzlich.net/gocryptfs/)
     15 
     16 ## Preparation
     17 
     18 Initilize gocryptfs with the Backup-source directory. If you want to backup
     19 (subdirectories of) your home-folder, do the following:
     20 
     21 ```bash
     22 gocryptfs \
     23     --init \ # initilise the volume
     24     --reverse \ # use "reverse mode"
     25     --plaintextnames \ # do not obfuscate names of files and directories
     26     "$HOME" # target directory. Here: our home-folder
     27 ```
     28 
     29 This will create a .gocryptfs.reverse.conf file with the encryption meta data.
     30 Do not lose this file or your encryption password.
     31 
     32 ## Usage
     33 
     34 To backup your home directory to a remote server via SSH, use following syntax:
     35 
     36 ```bash
     37 ./backup.sh "$HOME" "user[AT]example[DOT]com"
     38 ```
     39 
     40 Backups are stored on the remote end in the folder named after the hostname of
     41 your source machine and the current month. If you do monthly updates, this leads
     42 to 12 backup versions before the first backup is overwritten.