config.example.yaml

Sun, 04 Feb 2018 09:38:55 +0000

author
Tuomo Valkonen <tuomov@iki.fi>
date
Sun, 04 Feb 2018 09:38:55 +0000
changeset 104
d33e2d7dbeb1
parent 97
96d5adbe0205
permissions
-rw-r--r--

Added some debug log messages

25
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
1 #
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
2 # Borgend example configuration file
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
3 #
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
4
74
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
5 # General parameters for borg
25
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
6 borg:
74
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
7 executable: /usr/local/bin/borg
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
8 common_parameters:
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
9 create_parameters:
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
10 - exclude-from: $HOME/lib/borg-exclude-patterns.txt
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
11 prune_parameters:
97
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
12 # Set borg pruning parameters. The pruning interval is configured
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
13 # in each separate backup. NOTE: Pruning parameters can also be
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
14 # configured separately for each backup.
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
15 #
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
16 # Keep a daily archive for the last week
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
17 - keep-daily: 7
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
18 # Keep a weely archive for the last year
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
19 - keep-weekly: 52
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
20 # Keep a montly archive forever
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
21 - keep-monthly: -1
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
22 # Set to true to enable a dry-run
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
23 - dry-run: False
25
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
24
74
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
25 # Repositories: configure here locations, passphrases,
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
26 # and general access parameters
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
27 repositories:
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
28 - name: myserver
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
29 location: ssh://myserver.invalid/~/storage/borg
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
30 keychain_account: borg-backup@mylaptop
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
31 # Borg parameters
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
32 common_parameters:
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
33 # Borg is installed on remote host at ~/bin, which might not be on path
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
34 - remote-path: ~/bin/borg
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
35 create_parameters:
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
36 - compression: lzma
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
37 - checkpoint-interval: 600
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
38
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
39 - name: backup1
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
40 location: /Volumes/backup1/borg
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
41 keychain_account: borg-backup@mylaptop
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
42
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
43 # Backups: configure here which files should be backed up, how frequently, and to
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
44 # which repositires.
25
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
45 backups:
74
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
46 # 1. Most files in $HOME to ssh://myserver.invalid
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
47 - name: Home to 'myserver'
97
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
48 # Scheduling mode: dreamtime/realtime/manual
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
49 # Dreamtime scheduling discounts system sleep periods.
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
50 scheduling: dreamtime
74
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
51 # Backup every 24 hours
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
52 backup_interval: 86400
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
53 # Retry every 15 minutes if unable to connect / unfinished backup
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
54 retry_interval: 900
97
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
55 # Prune interval: once every two weeks
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
56 prune_interval: 1209600
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
57 # Repository and archive configuration
74
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
58 repository: myserver
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
59 archive_prefix: 'all@mylaptop-'
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
60 archive_template: '{now:%Y-%m-%d_%H:%M:%S}'
97
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
61 # Files to include
74
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
62 paths:
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
63 - $HOME
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
64 create_parameters:
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
65 - pattern: "- $HOME/Downloads/"
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
66 - pattern: "- $HOME/Library/Mail/V*/MailData/"
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
67 - pattern: "+ $HOME/Library/Mail/"
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
68 - pattern: "+ $HOME/Library/Mobile Documents/"
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
69 - pattern: "- $HOME/Library/"
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
70 - pattern: "- $HOME/.config/borg/security/"
25
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
71
74
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
72 # 2. A subset of files $HOME more frequently to ssh://myserver.invalid
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
73 - name: Work to 'myserver'
97
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
74 # Scheduling mode: dreamtime/realtime/manual
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
75 scheduling: dreamtime
76
4b08fca3ce34 Dreamtime scheduling: discount system sleep periods
Tuomo Valkonen <tuomov@iki.fi>
parents: 74
diff changeset
76 # Backup every 3 hours
4b08fca3ce34 Dreamtime scheduling: discount system sleep periods
Tuomo Valkonen <tuomov@iki.fi>
parents: 74
diff changeset
77 backup_interval: 10800
4b08fca3ce34 Dreamtime scheduling: discount system sleep periods
Tuomo Valkonen <tuomov@iki.fi>
parents: 74
diff changeset
78 # Retry every 15 minutes if unable to connect / unfinished backup
4b08fca3ce34 Dreamtime scheduling: discount system sleep periods
Tuomo Valkonen <tuomov@iki.fi>
parents: 74
diff changeset
79 retry_interval: 900
97
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
80 # Prune interval: once every two weeks
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
81 prune_interval: 1209600
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
82 # Repository and archive configuration
76
4b08fca3ce34 Dreamtime scheduling: discount system sleep periods
Tuomo Valkonen <tuomov@iki.fi>
parents: 74
diff changeset
83 repository: myserver
4b08fca3ce34 Dreamtime scheduling: discount system sleep periods
Tuomo Valkonen <tuomov@iki.fi>
parents: 74
diff changeset
84 archive_prefix: 'work@mylaptop-'
4b08fca3ce34 Dreamtime scheduling: discount system sleep periods
Tuomo Valkonen <tuomov@iki.fi>
parents: 74
diff changeset
85 archive_template: '{now:%Y-%m-%d_%H:%M:%S}'
4b08fca3ce34 Dreamtime scheduling: discount system sleep periods
Tuomo Valkonen <tuomov@iki.fi>
parents: 74
diff changeset
86 paths:
4b08fca3ce34 Dreamtime scheduling: discount system sleep periods
Tuomo Valkonen <tuomov@iki.fi>
parents: 74
diff changeset
87 - $HOME/work
65
6fed67863b00 README and config.example.yaml updates to describe queuing features
Tuomo Valkonen <tuomov@iki.fi>
parents: 25
diff changeset
88
74
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
89 # 3. Manual backup to external hard drive
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
90 - name: Home to 'backup1'
25
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
91 # Manual backup
76
4b08fca3ce34 Dreamtime scheduling: discount system sleep periods
Tuomo Valkonen <tuomov@iki.fi>
parents: 74
diff changeset
92 scheduling: manual
25
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
93 backup_interval: 0
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
94 retry_interval: 0
97
96d5adbe0205 Pruning support
Tuomo Valkonen <tuomov@iki.fi>
parents: 76
diff changeset
95 prune_interval: 0
74
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
96 repository: backup1
25
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
97 archive_prefix: 'mylaptop-'
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
98 archive_template: '{now:%Y-%m-%d_%H:%M:%S}'
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
99 paths:
74
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
100 - $HOME
25
efa4c61c6f01 Sample configuration file added along with a few words of documentation
Tuomo Valkonen <tuomov@iki.fi>
parents:
diff changeset
101 create_parameters:
74
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
102 - pattern: "- $HOME/Downloads/"
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
103 - pattern: "- $HOME/Library/Mail/V*/MailData/"
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
104 - pattern: "+ $HOME/Library/Mail/"
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
105 - pattern: "+ $HOME/Library/Mobile Documents/"
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
106 - pattern: "- $HOME/Library/"
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
107 - pattern: "- $HOME/.config/borg/security/"
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
108
4f56142e7497 Separated repository configuration form backup configuration;
Tuomo Valkonen <tuomov@iki.fi>
parents: 65
diff changeset
109

mercurial