2024-01-23 18:09:04 +00:00
|
|
|
Enhancement: Support reading backup from a commands's standard output
|
2023-10-01 14:34:30 +00:00
|
|
|
|
2024-01-21 21:06:54 +00:00
|
|
|
The `backup` command now supports the `--stdin-from-command` option. When using
|
2024-01-23 18:09:04 +00:00
|
|
|
this option, the arguments to `backup` are interpreted as a command instead of
|
|
|
|
paths to back up. `backup` then executes the given command and stores the
|
|
|
|
standard output from it in the backup, similar to the what the `--stdin` option
|
|
|
|
does. This also enables restic to verify that the command completes with exit
|
|
|
|
code zero. A non-zero exit code causes the backup to fail.
|
|
|
|
|
|
|
|
Note that the `--stdin` option does not have to be specified at the same time,
|
|
|
|
and that the `--stdin-filename` option also applies to `--stdin-from-command`.
|
2023-08-27 08:40:57 +00:00
|
|
|
|
2024-01-23 18:09:04 +00:00
|
|
|
Example: `restic backup --stdin-from-command --stdin-filename dump.sql mysqldump [...]`
|
2023-08-27 08:40:57 +00:00
|
|
|
|
|
|
|
https://github.com/restic/restic/issues/4251
|
|
|
|
https://github.com/restic/restic/pull/4410
|