9
9
# Global options: These options are used for all commands.
10
10
[global ]
11
11
use-profiles = []
12
- log-level = " info" # any of "off", "error", "warn", "info", "debug", "trace"; default: "info"
12
+ log-level = " info" # any of "off", "error", "warn", "info", "debug", "trace"; default: "info"
13
13
log-file = " /path/to/rustic.log" # Default: not set
14
14
no-progress = false
15
15
progress-interval = " 100ms"
@@ -20,7 +20,9 @@ check-index = false
20
20
[global .hooks ]
21
21
run-before = [
22
22
# long form giving command and args explicitly and allow to specify failure behavior
23
- { command = " echo" , args = [" before" ], on-failure = " warn" }, # allowed values for on-failure: "error" (default), "warn", "ignore"
23
+ { command = " echo" , args = [
24
+ " before" ,
25
+ ], on-failure = " warn" }, # allowed values for on-failure: "error" (default), "warn", "ignore"
24
26
] # Default: []
25
27
run-after = [" echo after" ] # Run after if successful, short version, default: []
26
28
run-failed = [" echo failed" ] # Default: []
@@ -35,31 +37,31 @@ RCLONE_XXX = "true"
35
37
# Repository options: These options define which backend to use and which password to use.
36
38
[repository ]
37
39
repository = " /repo/rustic" # Must be set
38
- repo-hot = " /my/hot/repo" # Default: not set
40
+ repo-hot = " /my/hot/repo" # Default: not set
39
41
# one of the three password options must be set
40
42
password = " mySecretPassword"
41
43
password-file = " /my/password.txt"
42
44
password-command = " my_command.sh"
43
45
no-cache = false
44
- cache-dir = " /my/rustic/cachedir" # Default: Applications default cache dir, e.g. ~/.cache/rustic
46
+ cache-dir = " /my/rustic/cachedir" # Default: Applications default cache dir, e.g. ~/.cache/rustic
45
47
# use either warm-up (warm-up by file access) or warm-up-command to specify warming up
46
48
warm-up = false
47
49
warm-up-command = " warmup.sh %id" # Default: not set
48
- warm-up-wait = " 10min" # Default: not set
50
+ warm-up-wait = " 10min" # Default: not set
49
51
50
52
# Additional repository options - depending on backend. These can be only set in the config file or using env variables.
51
53
# For env variables use upper snake case and prefix with "RUSTIC_REPO_OPT_", e.g. `use-passwort = "true"` becomes
52
54
# `RUSTIC_REPO_OPT_USE_PASSWORT=true`
53
55
[repository .options ]
54
- post-create-command = " par2create -qq -n1 -r5 %file" # Only local backend; Default: not set
55
- post-delete-command = " sh -c \" rm -f %file*.par2\" " # Only local backend; Default: not set
56
- retry = " default" # Only rest/rclone/all opendal backends; Allowed values: "false"/"off", "default" or number of retries
57
- timeout = " 10min" # Only rest/rclone backend
56
+ post-create-command = " par2create -qq -n1 -r5 %file" # Only local backend; Default: not set
57
+ post-delete-command = " sh -c \" rm -f %file*.par2\" " # Only local backend; Default: not set
58
+ retry = " default" # Only rest/rclone/all opendal backends; Allowed values: "false"/"off", "default" or number of retries
59
+ timeout = " 10min" # Only rest/rclone backend
58
60
rclone-command = " rclone serve restic --addr localhost:0" # Only rclone; Default: not set
59
- use-password = " true" # Only rclone
60
- rest-url = " http://localhost:8000" # Only rclone; Default: determine REST URL from rclone output
61
- connections = " 20" # Only opendal backends; Default: Not set
62
- throttle = " 10kB,10MB" # limit and burst per second; only opendal backends; Default: Not set
61
+ use-password = " true" # Only rclone
62
+ rest-url = " http://localhost:8000" # Only rclone; Default: determine REST URL from rclone output
63
+ connections = " 20" # Only opendal backends; Default: Not set
64
+ throttle = " 10kB,10MB" # limit and burst per second; only opendal backends; Default: Not set
63
65
# Note that opendal backends use several service-dependent options which may be specified here, see
64
66
# https://opendal.apache.org/docs/rust/opendal/services/index.html
65
67
@@ -77,42 +79,42 @@ throttle = "10kB,10MB" # limit and burst per second; only opendal backends; Defa
77
79
78
80
# Repository hooks: The given commands are called for commands accessing the repository.
79
81
[repository .hooks ]
80
- run-before = [" echo before" ] # Default: []
81
- run-after = [" echo after" ] # Run after if successful, default: []
82
- run-failed = [" echo failed" ] # Default: []
82
+ run-before = [" echo before" ] # Default: []
83
+ run-after = [" echo after" ] # Run after if successful, default: []
84
+ run-failed = [" echo failed" ] # Default: []
83
85
run-finally = [" echo finally" ] # Always run after, default: []
84
86
85
87
# Snapshot-filter options: These options apply to all commands that use snapshot filters
86
88
[snapshot-filter ]
87
- filter-hosts = [" host1" , " host2" ] # Default: []
88
- filter-labels = [" label1" , " label2" ] # Default: []
89
- filter-tags = [" tag1,tag2" , " tag3" ] # Default: []
90
- filter-tags-exact = [" tag1,tag2" , " tag2" ] # Default: []
91
- filter-paths = [" path1" , " path2,path3" ] # Default: []
92
- filter-paths-exact = [" path1" , " path2,path3" ] # Default: []
93
- filter-after = " 2024-01-01" # Default: not set
94
- filter-before = " 2024-02-05 12:15" # Default: not set
95
- filter-size = " 200MiB" # Default: not set
96
- filter-size-added = " 1 MB..10MB" # Default: not set
89
+ filter-hosts = [" host1" , " host2" ] # Default: []
90
+ filter-labels = [" label1" , " label2" ] # Default: []
91
+ filter-tags = [" tag1,tag2" , " tag3" ] # Default: []
92
+ filter-tags-exact = [" tag1,tag2" , " tag2" ] # Default: []
93
+ filter-paths = [" path1" , " path2,path3" ] # Default: []
94
+ filter-paths-exact = [" path1" , " path2,path3" ] # Default: []
95
+ filter-after = " 2024-01-01" # Default: not set
96
+ filter-before = " 2024-02-05 12:15" # Default: not set
97
+ filter-size = " 200MiB" # Default: not set
98
+ filter-size-added = " 1 MB..10MB" # Default: not set
97
99
filter-fn = ' |sn| {sn.host == "host1" || sn.description.contains("test")}' # Default: no filter function
98
100
99
101
# Backup options: These options are used for all sources when calling the backup command.
100
102
# They can be overwritten by source-specific options (see below) or command line options.
101
103
[backup ]
102
- label = " label" # Default: not set
104
+ label = " label" # Default: not set
103
105
tags = [" tag1" , " tag2" ]
104
- description = " my description" # Default: not set
105
- description-from = " /path/to/description.txt" # Default: not set
106
+ description = " my description" # Default: not set
107
+ description-from = " /path/to/description.txt" # Default: not set
106
108
delete-never = false
107
- delete-after = " 5d" # Default: not set
108
- host = " manually_set_host" # Default: host name
109
- group-by = " host,label,paths" # Can be any combination of host,label,paths,tags
110
- parent = " 123abc" # Default: not set
109
+ delete-after = " 5d" # Default: not set
110
+ host = " manually_set_host" # Default: host name
111
+ group-by = " host,label,paths" # Can be any combination of host,label,paths,tags
112
+ parent = " 123abc" # Default: not set
111
113
force = false
112
114
ignore-ctime = false
113
115
ignore-inode = false
114
- stdin-filename = " stdin" # Only for stdin source
115
- as-path = " /my/path" # Default: not set; Note: This only works if source contains of a single path.
116
+ stdin-filename = " stdin" # Only for stdin source
117
+ as-path = " /my/path" # Default: not set; Note: This only works if source contains of a single path.
116
118
with-atime = false
117
119
ignore-devid = false
118
120
globs = []
@@ -121,10 +123,10 @@ glob-files = []
121
123
iglob-files = []
122
124
git-ignore = false
123
125
no-require-git = false
124
- exclude-if-present = [" .nobackup" , " CACHEDIR.TAG" ] # Default: not set
126
+ exclude-if-present = [" .nobackup" , " CACHEDIR.TAG" ] # Default: not set
125
127
custom-ignorefiles = [" .rusticignore" , " .backupignore" ] # Default: not set
126
128
one-file-system = false
127
- exclude-larger-than = " 100MB" # Default: not set
129
+ exclude-larger-than = " 100MB" # Default: not set
128
130
json = false
129
131
init = false
130
132
no-scan = false
@@ -133,22 +135,22 @@ skip-identical-parent = false
133
135
134
136
# Backup hooks: The given commands are called for the `backup` command
135
137
[backup .hooks ]
136
- run-before = [" echo before" ] # Default: []
137
- run-after = [" echo after" ] # Run after if successful, default: []
138
- run-failed = [" echo failed" ] # Default: []
138
+ run-before = [" echo before" ] # Default: []
139
+ run-after = [" echo after" ] # Run after if successful, default: []
140
+ run-failed = [" echo failed" ] # Default: []
139
141
run-finally = [" echo finally" ] # Always run after, default: []
140
142
141
143
# Backup options for specific sources - all above options are also available here and replace them for the given source
142
144
[[backup .snapshots ]]
143
145
sources = [" /path/to/source1" ]
144
- label = " label" # Default: not set
146
+ label = " label" # Default: not set
145
147
# .. and so on. see [backup]
146
148
147
149
# Source-specific hooks: The given commands when backing up the defined source
148
150
[backup .snapshots .hooks ]
149
- run-before = [" echo before" ] # Default: []
150
- run-after = [" echo after" ] # Run after if successful, default: []
151
- run-failed = [" echo failed" ] # Default: []
151
+ run-before = [" echo before" ] # Default: []
152
+ run-after = [" echo after" ] # Run after if successful, default: []
153
+ run-failed = [" echo failed" ] # Default: []
152
154
run-finally = [" echo finally" ] # Always run after, default: []
153
155
154
156
[[backup .snapshots ]]
@@ -163,16 +165,16 @@ sources = [
163
165
prune = false
164
166
group-by = " host,label,paths" # Can be any combination of host,label,paths,tags
165
167
# The following filter options can be also defined here and then overwrite the options for the forget command
166
- filter-hosts = [" host1" , " host2" ] # Default: []
167
- filter-labels = [" label1" , " label2" ] # Default: []
168
- filter-tags = [" tag1,tag2" , " tag3" ] # Default: []
169
- filter-tags-exact = [" tag1,tag2" , " tag2" ] # Default: []
170
- filter-paths = [" path1" , " path2,path3" ] # Default: []
171
- filter-paths-exact = [" path1" , " path2,path3" ] # Default: []
172
- filter-after = " 2024-01-01" # Default: not set
173
- filter-before = " 2024-02-05 12:15" # Default: not set
174
- filter-size = " 200MiB" # Default: not set
175
- filter-size-added = " 1 MB..10MB" # Default: not set
168
+ filter-hosts = [" host1" , " host2" ] # Default: []
169
+ filter-labels = [" label1" , " label2" ] # Default: []
170
+ filter-tags = [" tag1,tag2" , " tag3" ] # Default: []
171
+ filter-tags-exact = [" tag1,tag2" , " tag2" ] # Default: []
172
+ filter-paths = [" path1" , " path2,path3" ] # Default: []
173
+ filter-paths-exact = [" path1" , " path2,path3" ] # Default: []
174
+ filter-after = " 2024-01-01" # Default: not set
175
+ filter-before = " 2024-02-05 12:15" # Default: not set
176
+ filter-size = " 200MiB" # Default: not set
177
+ filter-size-added = " 1 MB..10MB" # Default: not set
176
178
filter-fn = ' |sn| {sn.host == "host1" || sn.description.contains("test")}' # Default: no filter function
177
179
# The retention options follow. All of these are not set by default.
178
180
keep-tags = [" tag1" , " tag2,tag3" ] # Default: not set
@@ -181,13 +183,15 @@ keep-ids = [
181
183
" 11122233" ,
182
184
] # Keep all snapshots whose ID starts with any of these strings, default: not set
183
185
keep-last = 0
186
+ keep-minutely = 10
184
187
keep-daily = 3
185
188
keep-weekly = 0
186
189
keep-monthly = 0
187
190
keep-quarter-yearly = 0
188
191
keep-half-yearly = 0
189
192
keep-yearly = 10
190
193
keep-within = " 0s"
194
+ keep-within-minutely = " 2 hours"
191
195
keep-within-daily = " 0 seconds"
192
196
keep-within-weekly = " 2 months"
193
197
keep-within-monthly = " 1 year"
@@ -201,10 +205,10 @@ targets = ["profile1", "profile2"] # Default: []
201
205
[webdav ]
202
206
address = " localhost:8000"
203
207
path-template = " [{hostname}]/[{label}]/{time}" # The path template to use for snapshots. {id}, {id_long}, {time}, {username}, {hostname}, {label}, {tags}, {backup_start}, {backup_end} are replaced. [default: "[{hostname}]/[{label}]/{time}"]. Only relevant if no snapshot-path is given.
204
- time-template = " %Y-%m-%d_%H-%M-%S" # only relevant if no snapshot-path is given
208
+ time-template = " %Y-%m-%d_%H-%M-%S" # only relevant if no snapshot-path is given
205
209
symlinks = false
206
- file-access = " read" # Default: "forbidden" for hot/cold repos, else "read"
207
- snapshot-path = " latest:/dir" # Default: not set - if not set, generate a virtual tree with all snapshots using path-template
210
+ file-access = " read" # Default: "forbidden" for hot/cold repos, else "read"
211
+ snapshot-path = " latest:/dir" # Default: not set - if not set, generate a virtual tree with all snapshots using path-template
208
212
209
213
[mount ]
210
214
path-template = " [{hostname}]/[{label}]/{time}" # The path template to use for snapshots. {id}, {id_long}, {time}, {username}, {hostname}, {label}, {tags}, {backup_start}, {backup_end} are replaced. [default: "[{hostname}]/[{label}]/{time}"]. Only relevant if no snapshot-path is given.
0 commit comments