mirror of
https://github.com/roles-ansible/ansible_role_restic.git
synced 2024-12-11 23:41:32 +01:00
Merge pull request #40 from z-bsod/main
README.md: Backup from stdin - clarify `src` variable and add example for a backup job using stdin
This commit is contained in:
commit
abe671db58
1 changed files with 9 additions and 1 deletions
10
README.md
10
README.md
|
@ -121,7 +121,7 @@ Available variables:
|
||||||
| ------------------ |:-----------------------------:| ------------ |
|
| ------------------ |:-----------------------------:| ------------ |
|
||||||
| `name` | yes | The name of this backup. Used together with pruning and scheduling and needs to be unique. |
|
| `name` | yes | The name of this backup. Used together with pruning and scheduling and needs to be unique. |
|
||||||
| `repo` | yes | The name of the repository to backup to. |
|
| `repo` | yes | The name of the repository to backup to. |
|
||||||
| `src` | yes | The source directory or file |
|
| `src` | yes (unless `stdin` == `true`) | The source directory or file |
|
||||||
| `stdin` | no | Is this backup created from a [stdin](https://restic.readthedocs.io/en/stable/040_backup.html#reading-data-from-stdin)? |
|
| `stdin` | no | Is this backup created from a [stdin](https://restic.readthedocs.io/en/stable/040_backup.html#reading-data-from-stdin)? |
|
||||||
| `stdin_cmd` | no (yes if `stdin` == `true`) | The command to produce the stdin. |
|
| `stdin_cmd` | no (yes if `stdin` == `true`) | The command to produce the stdin. |
|
||||||
| `stdin_filename` | no | The filename used in the repository. |
|
| `stdin_filename` | no | The filename used in the repository. |
|
||||||
|
@ -156,6 +156,14 @@ restic_backups:
|
||||||
src: /path/to/data
|
src: /path/to/data
|
||||||
scheduled: true
|
scheduled: true
|
||||||
schedule_oncalendar: '*-*-* 01:00:00'
|
schedule_oncalendar: '*-*-* 01:00:00'
|
||||||
|
database:
|
||||||
|
name: database
|
||||||
|
repo: remove
|
||||||
|
stdin: true
|
||||||
|
stdin_cmd: pg_dump -Ubackup db_name
|
||||||
|
stdin_filename: db_name_dump.sql
|
||||||
|
scheduled: true
|
||||||
|
schedule_oncalendar: '*-*-* 01:30:00'
|
||||||
```
|
```
|
||||||
|
|
||||||
> You can also specify restic_backups as an array, which is a legacy feature and
|
> You can also specify restic_backups as an array, which is a legacy feature and
|
||||||
|
|
Loading…
Reference in a new issue