You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
*[More complex configuration in TOML](#more-complex-configuration-in-toml)
67
68
*[TOML configuration example for Windows](#toml-configuration-example-for-windows)
68
-
*[Use stdin in configuration](#use-stdin-in-configuration)
69
+
*[Use stdin in configuration](#use-stdin-in-configuration)
70
+
*[Special case for the copy command section](#special-case-for-the-copy-command-section)
69
71
*[Configuration paths](#configuration-paths)
70
72
*[macOS X](#macos-x)
71
73
*[Other unixes (Linux and BSD)](#other-unixes-linux-and-bsd)
@@ -212,7 +214,7 @@ Installation using Ansible is not supported out of the box yet, but since I'm us
212
214
213
215
## Installation from source
214
216
215
-
You can download the source code and recompile it, it's actually very easy! all you need to have on your machine is:
217
+
You can download the source code and compile it, it's actually very easy! all you need to have on your machine is:
216
218
-`git`
217
219
-[go compiler](https://golang.org/dl/)
218
220
-`GNU Make` which is installed by default on many unix boxes. On debian based distributions (Ubuntu included) the package is called `build-essential`.
@@ -555,7 +557,7 @@ run-after = "echo All Done!"
555
557
no-error-on-warning = true
556
558
```
557
559
558
-
###Use stdin in configuration
560
+
## Use stdin in configuration
559
561
560
562
Simple example sending a file via stdin
561
563
@@ -572,6 +574,37 @@ tag = [ 'stdin' ]
572
574
573
575
```
574
576
577
+
## Special case for the `copy` command section
578
+
579
+
The copy command needs two repository (and quite likely 2 different set of keys). You can configure a `copy` section like this:
580
+
581
+
```toml
582
+
[default]
583
+
initialize = false
584
+
repository = "/backup/original"
585
+
password-file = "key"
586
+
587
+
[default.copy]
588
+
initialize = true
589
+
repository = "/backup/copy"
590
+
password-file = "other_key"
591
+
```
592
+
593
+
You will note that the secondary repository doesn't need to have a `2` behind its flags (`repository2`, `password-file2`, etc.). It's because the flags are well separated in the configuration.
594
+
595
+
Here's the same configuration in YAML format:
596
+
597
+
```yaml
598
+
default:
599
+
initialize: false
600
+
repository: "/backup/original"
601
+
password-file: key
602
+
copy:
603
+
initialize: true
604
+
repository: "/backup/copy"
605
+
password-file: other_key
606
+
```
607
+
575
608
# Configuration paths
576
609
577
610
The default name for the configuration file is `profiles`, without an extension.
@@ -957,13 +990,14 @@ global:
957
990
958
991
Each profile can be scheduled independently (groups are not available for scheduling yet).
959
992
960
-
These 4 profile sections are accepting a schedule configuration:
993
+
These 5 profile sections are accepting a schedule configuration:
961
994
- backup
962
995
- check
963
996
- forget (version 0.11.0)
964
997
- prune (version 0.11.0)
998
+
- copy (version 0.16.0)
965
999
966
-
which mean you can schedule `backup`, `forget`, `prune`and `check` independently (I recommend to use a local `lock` in this case).
1000
+
which mean you can schedule `backup`, `forget`, `prune`, `check`and `copy` independently (I recommend to use a local `lock` in this case).
967
1001
968
1002
## retention schedule is deprecated
969
1003
**Important**:
@@ -2075,6 +2109,7 @@ Flags passed to the restic command line
2075
2109
***password-file**: string
2076
2110
***quiet**: true / false
2077
2111
***repository**: string **(will be passed as 'repo' to the command line)**
2112
+
***repository-file**: string
2078
2113
***tls-client-cert**: string
2079
2114
***verbose**: true / false OR integer
2080
2115
@@ -2223,6 +2258,24 @@ Flags passed to the restic command line
2223
2258
***snapshot-template**: string
2224
2259
***tag**: string OR list of strings
2225
2260
2261
+
`[profile.copy]`
2262
+
2263
+
Flags used by resticprofile only
2264
+
2265
+
***initialize**: true / false
2266
+
2267
+
2268
+
Flags passed to the restic command line
2269
+
2270
+
***key-hint**: string
2271
+
***password-command**: command
2272
+
***password-file**: string
2273
+
***path**: string OR list of strings
2274
+
***repository**: repository
2275
+
***repository-file**: string
2276
+
***tag**: string OR list of strings
2277
+
2278
+
2226
2279
# Appendix
2227
2280
2228
2281
As an example, here's a similar configuration file in YAML:
0 commit comments