docs: better backup docs

This commit is contained in:
decentral1se 2022-04-19 13:01:04 +02:00
parent a4f1634b24
commit 10d5705d1a
Signed by: decentral1se
GPG Key ID: 03789458B3D0C410
1 changed files with 19 additions and 5 deletions

View File

@ -48,13 +48,27 @@ var appBackupCommand = cli.Command{
This command runs an app backup. This command runs an app backup.
A backup command and pre/post hook commands are defined in the recipe A backup command and pre/post hook commands are defined in the recipe
configuration. Abra reads this config and run the comands in the context of the configuration. Abra reads this configuration and run the comands in the context
service. Pass <service> if you only want to back up a single service. All of the deployed services. Pass <service> if you only want to back up a single
backups are placed in the ~/.abra/backups directory. service. All backups are placed in the ~/.abra/backups directory.
Example: A single backup file is produced for all backup paths specified for a service.
If we have the following backup configuration:
abra app backup example.com db - "backupbot.backup.path=/var/lib/foo,/var/lib/bar"
And we run "abra app backup example.com app", Abra will produce a file that
looks like:
~/.abra/backups/example_com_app_609341138.tar.gz
This file is a compressed archive which contains all backup paths. To see paths, run:
tar -tf ~/.abra/backups/example_com_app_609341138.tar.gz
(Make sure to change the name of the backup file)
This single file can be used to restore your app. See "abra app restore" for more.
`, `,
Action: func(c *cli.Context) error { Action: func(c *cli.Context) error {
app := internal.ValidateApp(c) app := internal.ValidateApp(c)