From 3029259d8208af283c0f08d72b76ee64808ee5f8 Mon Sep 17 00:00:00 2001 From: cupcakearmy Date: Sun, 21 Nov 2021 21:06:25 +0100 Subject: [PATCH] docs --- docs/markdown/backend/overview.md | 2 ++ docs/markdown/config.md | 4 ++++ docs/markdown/location/forget.md | 15 +++++++++++++++ docs/markdown/location/overview.md | 8 +++++++- docs/markdown/quick.md | 8 +++++++- 5 files changed, 35 insertions(+), 2 deletions(-) diff --git a/docs/markdown/backend/overview.md b/docs/markdown/backend/overview.md index e0d4aae..0c2092a 100644 --- a/docs/markdown/backend/overview.md +++ b/docs/markdown/backend/overview.md @@ -3,6 +3,8 @@ Backends are the outputs of the backup process. Each location needs at least one. ```yaml | .autorestic.yml +version: 2 + backends: name-of-backend: type: local diff --git a/docs/markdown/config.md b/docs/markdown/config.md index f0761bf..ee4e285 100644 --- a/docs/markdown/config.md +++ b/docs/markdown/config.md @@ -16,6 +16,8 @@ You can also specify a custom file with the `-c path/to/some/config.yml` ## Example configuration ```yaml | .autorestic.yml +version: 2 + locations: home: from: /home/me @@ -49,6 +51,8 @@ Aliases allow to reuse snippets of config throughout the same file. The following example shows how the locations `a` and `b` share the same hooks and forget policies. ```yaml | .autorestic.yml +version: 2 + extras: hooks: &foo before: diff --git a/docs/markdown/location/forget.md b/docs/markdown/location/forget.md index ad17c2c..db4ed84 100644 --- a/docs/markdown/location/forget.md +++ b/docs/markdown/location/forget.md @@ -7,6 +7,8 @@ This is based on [Restic's snapshots policies](https://restic.readthedocs.io/en/ > **Note** This is a full example, of course you also can specify only one of them ```yaml | .autorestic.yml +version: 2 + locations: etc: from: /etc @@ -22,4 +24,17 @@ locations: keep-within: '2w' # keep snapshots from the last 2 weeks ``` +## Globally + +You can specify global forget policies that would be applied to all locations: + +```yaml | .autorestic.yml +version: 2 + +global: + forget: + keep-daily: 30 + keep-weekly: 52 +``` + > :ToCPrevNext diff --git a/docs/markdown/location/overview.md b/docs/markdown/location/overview.md index c92a7e0..1b3dd96 100644 --- a/docs/markdown/location/overview.md +++ b/docs/markdown/location/overview.md @@ -4,9 +4,15 @@ Locations can be seen as the input to the backup process. Generally this is simp The paths can be relative from the config file. A location can have multiple backends, so that the data is secured across multiple servers. ```yaml | .autorestic.yml +version: 2 + locations: my-location-name: from: path/to/backup + # Or multiple + # from: + # - /a + # - /b to: - name-of-backend - also-backup-to-this-backend @@ -14,7 +20,7 @@ locations: ## `from` -This is the source of the location. +This is the source of the location. Can be an `array` for multiple sources. #### How are paths resolved? diff --git a/docs/markdown/quick.md b/docs/markdown/quick.md index 574bc03..37e776e 100644 --- a/docs/markdown/quick.md +++ b/docs/markdown/quick.md @@ -25,9 +25,15 @@ For a quick overview: > Note that the data is automatically encrypted on the server. The key will be generated and added to your config file. Every backend will have a separate key. **You should keep a copy of the keys or config file somewhere in case your server dies**. Otherwise DATA IS LOST! ```yaml | .autorestic.yml +version: 2 + locations: home: - from: /home/me + from: /home + # Or multiple + # from: + # - /foo + # - /bar to: remote important: