Skip to content

Commit 793ae0f

Browse files
authored
feat(cli): onboard iaas volume backup api (#773)
relates to STACKITCLI-192
1 parent cf9ff84 commit 793ae0f

28 files changed

+2737
-32
lines changed

docs/stackit_volume.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ stackit volume [flags]
3030
### SEE ALSO
3131

3232
* [stackit](./stackit.md) - Manage STACKIT resources using the command line
33+
* [stackit volume backup](./stackit_volume_backup.md) - Provides functionality for volume backups
3334
* [stackit volume create](./stackit_volume_create.md) - Creates a volume
3435
* [stackit volume delete](./stackit_volume_delete.md) - Deletes a volume
3536
* [stackit volume describe](./stackit_volume_describe.md) - Shows details of a volume

docs/stackit_volume_backup.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
## stackit volume backup
2+
3+
Provides functionality for volume backups
4+
5+
### Synopsis
6+
7+
Provides functionality for volume backups.
8+
9+
```
10+
stackit volume backup [flags]
11+
```
12+
13+
### Options
14+
15+
```
16+
-h, --help Help for "stackit volume backup"
17+
```
18+
19+
### Options inherited from parent commands
20+
21+
```
22+
-y, --assume-yes If set, skips all confirmation prompts
23+
--async If set, runs the command asynchronously
24+
-o, --output-format string Output format, one of ["json" "pretty" "none" "yaml"]
25+
-p, --project-id string Project ID
26+
--region string Target region for region-specific requests
27+
--verbosity string Verbosity of the CLI, one of ["debug" "info" "warning" "error"] (default "info")
28+
```
29+
30+
### SEE ALSO
31+
32+
* [stackit volume](./stackit_volume.md) - Provides functionality for volumes
33+
* [stackit volume backup create](./stackit_volume_backup_create.md) - Creates a backup from a specific source
34+
* [stackit volume backup delete](./stackit_volume_backup_delete.md) - Deletes a backup
35+
* [stackit volume backup describe](./stackit_volume_backup_describe.md) - Describes a backup
36+
* [stackit volume backup list](./stackit_volume_backup_list.md) - Lists all backups
37+
* [stackit volume backup restore](./stackit_volume_backup_restore.md) - Restores a backup
38+
* [stackit volume backup update](./stackit_volume_backup_update.md) - Updates a backup
39+

docs/stackit_volume_backup_create.md

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
## stackit volume backup create
2+
3+
Creates a backup from a specific source
4+
5+
### Synopsis
6+
7+
Creates a backup from a specific source (volume or snapshot).
8+
9+
```
10+
stackit volume backup create [flags]
11+
```
12+
13+
### Examples
14+
15+
```
16+
Create a backup from a volume
17+
$ stackit volume backup create --source-id xxx --source-type volume
18+
19+
Create a backup from a snapshot with a name
20+
$ stackit volume backup create --source-id xxx --source-type snapshot --name my-backup
21+
22+
Create a backup with labels
23+
$ stackit volume backup create --source-id xxx --source-type volume --labels key1=value1,key2=value2
24+
```
25+
26+
### Options
27+
28+
```
29+
-h, --help Help for "stackit volume backup create"
30+
--labels stringToString Key-value string pairs as labels (default [])
31+
--name string Name of the backup
32+
--source-id string ID of the source from which a backup should be created
33+
--source-type string Source type of the backup, one of ["volume" "snapshot"]
34+
```
35+
36+
### Options inherited from parent commands
37+
38+
```
39+
-y, --assume-yes If set, skips all confirmation prompts
40+
--async If set, runs the command asynchronously
41+
-o, --output-format string Output format, one of ["json" "pretty" "none" "yaml"]
42+
-p, --project-id string Project ID
43+
--region string Target region for region-specific requests
44+
--verbosity string Verbosity of the CLI, one of ["debug" "info" "warning" "error"] (default "info")
45+
```
46+
47+
### SEE ALSO
48+
49+
* [stackit volume backup](./stackit_volume_backup.md) - Provides functionality for volume backups
50+

docs/stackit_volume_backup_delete.md

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
## stackit volume backup delete
2+
3+
Deletes a backup
4+
5+
### Synopsis
6+
7+
Deletes a backup by its ID.
8+
9+
```
10+
stackit volume backup delete BACKUP_ID [flags]
11+
```
12+
13+
### Examples
14+
15+
```
16+
Delete a backup with ID "xxx"
17+
$ stackit volume backup delete xxx
18+
```
19+
20+
### Options
21+
22+
```
23+
-h, --help Help for "stackit volume backup delete"
24+
```
25+
26+
### Options inherited from parent commands
27+
28+
```
29+
-y, --assume-yes If set, skips all confirmation prompts
30+
--async If set, runs the command asynchronously
31+
-o, --output-format string Output format, one of ["json" "pretty" "none" "yaml"]
32+
-p, --project-id string Project ID
33+
--region string Target region for region-specific requests
34+
--verbosity string Verbosity of the CLI, one of ["debug" "info" "warning" "error"] (default "info")
35+
```
36+
37+
### SEE ALSO
38+
39+
* [stackit volume backup](./stackit_volume_backup.md) - Provides functionality for volume backups
40+
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
## stackit volume backup describe
2+
3+
Describes a backup
4+
5+
### Synopsis
6+
7+
Describes a backup by its ID.
8+
9+
```
10+
stackit volume backup describe BACKUP_ID [flags]
11+
```
12+
13+
### Examples
14+
15+
```
16+
Get details of a backup with ID "xxx"
17+
$ stackit volume backup describe xxx
18+
19+
Get details of a backup with ID "xxx" in JSON format
20+
$ stackit volume backup describe xxx --output-format json
21+
```
22+
23+
### Options
24+
25+
```
26+
-h, --help Help for "stackit volume backup describe"
27+
```
28+
29+
### Options inherited from parent commands
30+
31+
```
32+
-y, --assume-yes If set, skips all confirmation prompts
33+
--async If set, runs the command asynchronously
34+
-o, --output-format string Output format, one of ["json" "pretty" "none" "yaml"]
35+
-p, --project-id string Project ID
36+
--region string Target region for region-specific requests
37+
--verbosity string Verbosity of the CLI, one of ["debug" "info" "warning" "error"] (default "info")
38+
```
39+
40+
### SEE ALSO
41+
42+
* [stackit volume backup](./stackit_volume_backup.md) - Provides functionality for volume backups
43+

docs/stackit_volume_backup_list.md

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
## stackit volume backup list
2+
3+
Lists all backups
4+
5+
### Synopsis
6+
7+
Lists all backups in a project.
8+
9+
```
10+
stackit volume backup list [flags]
11+
```
12+
13+
### Examples
14+
15+
```
16+
List all backups
17+
$ stackit volume backup list
18+
19+
List all backups in JSON format
20+
$ stackit volume backup list --output-format json
21+
22+
List up to 10 backups
23+
$ stackit volume backup list --limit 10
24+
25+
List backups with specific labels
26+
$ stackit volume backup list --label-selector key1=value1,key2=value2
27+
```
28+
29+
### Options
30+
31+
```
32+
-h, --help Help for "stackit volume backup list"
33+
--label-selector string Filter backups by labels
34+
--limit int Maximum number of entries to list
35+
```
36+
37+
### Options inherited from parent commands
38+
39+
```
40+
-y, --assume-yes If set, skips all confirmation prompts
41+
--async If set, runs the command asynchronously
42+
-o, --output-format string Output format, one of ["json" "pretty" "none" "yaml"]
43+
-p, --project-id string Project ID
44+
--region string Target region for region-specific requests
45+
--verbosity string Verbosity of the CLI, one of ["debug" "info" "warning" "error"] (default "info")
46+
```
47+
48+
### SEE ALSO
49+
50+
* [stackit volume backup](./stackit_volume_backup.md) - Provides functionality for volume backups
51+

docs/stackit_volume_backup_restore.md

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
## stackit volume backup restore
2+
3+
Restores a backup
4+
5+
### Synopsis
6+
7+
Restores a backup by its ID.
8+
9+
```
10+
stackit volume backup restore BACKUP_ID [flags]
11+
```
12+
13+
### Examples
14+
15+
```
16+
Restore a backup with ID "xxx"
17+
$ stackit volume backup restore xxx
18+
```
19+
20+
### Options
21+
22+
```
23+
-h, --help Help for "stackit volume backup restore"
24+
```
25+
26+
### Options inherited from parent commands
27+
28+
```
29+
-y, --assume-yes If set, skips all confirmation prompts
30+
--async If set, runs the command asynchronously
31+
-o, --output-format string Output format, one of ["json" "pretty" "none" "yaml"]
32+
-p, --project-id string Project ID
33+
--region string Target region for region-specific requests
34+
--verbosity string Verbosity of the CLI, one of ["debug" "info" "warning" "error"] (default "info")
35+
```
36+
37+
### SEE ALSO
38+
39+
* [stackit volume backup](./stackit_volume_backup.md) - Provides functionality for volume backups
40+

docs/stackit_volume_backup_update.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
## stackit volume backup update
2+
3+
Updates a backup
4+
5+
### Synopsis
6+
7+
Updates a backup by its ID.
8+
9+
```
10+
stackit volume backup update BACKUP_ID [flags]
11+
```
12+
13+
### Examples
14+
15+
```
16+
Update the name of a backup with ID "xxx"
17+
$ stackit volume backup update xxx --name new-name
18+
19+
Update the labels of a backup with ID "xxx"
20+
$ stackit volume backup update xxx --labels key1=value1,key2=value2
21+
```
22+
23+
### Options
24+
25+
```
26+
-h, --help Help for "stackit volume backup update"
27+
--labels stringToString Key-value string pairs as labels (default [])
28+
--name string Name of the backup
29+
```
30+
31+
### Options inherited from parent commands
32+
33+
```
34+
-y, --assume-yes If set, skips all confirmation prompts
35+
--async If set, runs the command asynchronously
36+
-o, --output-format string Output format, one of ["json" "pretty" "none" "yaml"]
37+
-p, --project-id string Project ID
38+
--region string Target region for region-specific requests
39+
--verbosity string Verbosity of the CLI, one of ["debug" "info" "warning" "error"] (default "info")
40+
```
41+
42+
### SEE ALSO
43+
44+
* [stackit volume backup](./stackit_volume_backup.md) - Provides functionality for volume backups
45+

go.mod

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,11 @@ require (
1818
github.com/stackitcloud/stackit-sdk-go/core v0.17.2
1919
github.com/stackitcloud/stackit-sdk-go/services/alb v0.5.0
2020
github.com/stackitcloud/stackit-sdk-go/services/authorization v0.7.0
21-
github.com/stackitcloud/stackit-sdk-go/services/dns v0.15.1
22-
github.com/stackitcloud/stackit-sdk-go/services/git v0.5.1
21+
github.com/stackitcloud/stackit-sdk-go/services/dns v0.15.0
22+
github.com/stackitcloud/stackit-sdk-go/services/git v0.5.0
2323
github.com/stackitcloud/stackit-sdk-go/services/iaas v0.24.0
24-
github.com/stackitcloud/stackit-sdk-go/services/mongodbflex v1.2.1
25-
github.com/stackitcloud/stackit-sdk-go/services/opensearch v0.23.1
24+
github.com/stackitcloud/stackit-sdk-go/services/mongodbflex v1.2.0
25+
github.com/stackitcloud/stackit-sdk-go/services/opensearch v0.23.0
2626
github.com/stackitcloud/stackit-sdk-go/services/postgresflex v1.1.0
2727
github.com/stackitcloud/stackit-sdk-go/services/resourcemanager v0.16.0
2828
github.com/stackitcloud/stackit-sdk-go/services/runcommand v1.2.1

go.sum

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -568,10 +568,10 @@ github.com/stackitcloud/stackit-sdk-go/services/alb v0.5.0 h1:7UKUi7Od7KpuVjV4I/
568568
github.com/stackitcloud/stackit-sdk-go/services/alb v0.5.0/go.mod h1:RBLBx00zF9MoA/mcLoWwYaACFE0xrWp/EHlzo5S7nhA=
569569
github.com/stackitcloud/stackit-sdk-go/services/authorization v0.7.0 h1:VpONplkdlEh7Pf22+cNnnHH4bx+S9QI+z55XYRE74JY=
570570
github.com/stackitcloud/stackit-sdk-go/services/authorization v0.7.0/go.mod h1:dJ19ZwFjp2bfC5ZobXV3vUdSpE3quUw3GuoFSKLpHIo=
571-
github.com/stackitcloud/stackit-sdk-go/services/dns v0.15.1 h1:+7iIR5r2epGNkAcuERX4kEg1H8hz2yR9+/zLYqZR7Xk=
572-
github.com/stackitcloud/stackit-sdk-go/services/dns v0.15.1/go.mod h1:xhAdw016dY/hVsLerlExSMocqCc872+S0y1CdV3jAjU=
573-
github.com/stackitcloud/stackit-sdk-go/services/git v0.5.1 h1:xs8CMY7t8nULQvZr5+XZRs8yWw8YMVw+HfjcuMhieR4=
574-
github.com/stackitcloud/stackit-sdk-go/services/git v0.5.1/go.mod h1:agI7SONeLR/IZL3TOgn1tDzfS63O2rWKQE8+huRjEzU=
571+
github.com/stackitcloud/stackit-sdk-go/services/dns v0.15.0 h1:GQAA9gqhKN0ZRc1vRYURHeVjSghh+iF+5DK0HdeuakI=
572+
github.com/stackitcloud/stackit-sdk-go/services/dns v0.15.0/go.mod h1:PMHoavoIaRZpkI9BA0nsnRjGoHASVSBon45XB3QyhMA=
573+
github.com/stackitcloud/stackit-sdk-go/services/git v0.5.0 h1:s0A2EPBrnBxfKStKA/B1izbyYHw/0m2RdqN3Inkv9hI=
574+
github.com/stackitcloud/stackit-sdk-go/services/git v0.5.0/go.mod h1:XhXHJpOVC9Rpwyf1G+EpMbprBafH9aZb8vWBdR+z0WM=
575575
github.com/stackitcloud/stackit-sdk-go/services/iaas v0.24.0 h1:aLlZmcsDHqqc7KPsevvs+W6EPZFT51u/dx5TcVQsE6g=
576576
github.com/stackitcloud/stackit-sdk-go/services/iaas v0.24.0/go.mod h1:TaMx7kukGpRm0BkNCmS7u2x12q1pgfbD55DAnLIjOIQ=
577577
github.com/stackitcloud/stackit-sdk-go/services/loadbalancer v1.4.0 h1:Ef4SyTBjIkfwaws4mssa6AoK+OokHFtr7ZIflUpoXVE=
@@ -580,14 +580,14 @@ github.com/stackitcloud/stackit-sdk-go/services/logme v0.24.1 h1:hfnILDJGBwwqUIs
580580
github.com/stackitcloud/stackit-sdk-go/services/logme v0.24.1/go.mod h1:XjDMHhAQogFXsVR+o138CPYG1FOe0/Nl2Vm+fAgzx2A=
581581
github.com/stackitcloud/stackit-sdk-go/services/mariadb v0.24.1 h1:7nN7ZCuWSbJMy5KqoOqSbp5JKIOvyuDqVRtxVvT1iyE=
582582
github.com/stackitcloud/stackit-sdk-go/services/mariadb v0.24.1/go.mod h1:Pb8IEV5/jP8k75dVcN5cn3kP7PHTy/4KXXKpG76oj4U=
583-
github.com/stackitcloud/stackit-sdk-go/services/mongodbflex v1.2.1 h1:TWz7qJ4Mg5pquDXODSZ1dzhS95ZYn3w1aKjuRU2VqCg=
584-
github.com/stackitcloud/stackit-sdk-go/services/mongodbflex v1.2.1/go.mod h1:U1Zf/S9IuDvRJq1tRKFT/bsJd4qxYzwtukqX3TL++Mw=
583+
github.com/stackitcloud/stackit-sdk-go/services/mongodbflex v1.2.0 h1:U/IhjLOz0vG6zuxTqGhBd8f609s6JB+X9PaL6x/VM58=
584+
github.com/stackitcloud/stackit-sdk-go/services/mongodbflex v1.2.0/go.mod h1:+JSnz5/AvGN5ek/iH008frRc/NgjSr1EVOTIbyLwAuQ=
585585
github.com/stackitcloud/stackit-sdk-go/services/objectstorage v1.2.0 h1:+dKIPVz9ydKbX3x6+1NvYk++OA378w74p+N6SjDmzBQ=
586586
github.com/stackitcloud/stackit-sdk-go/services/objectstorage v1.2.0/go.mod h1:iCOYS9yICXQPyMAIdUGMqJDLY8HXKiVAdiMzO/mPvtA=
587587
github.com/stackitcloud/stackit-sdk-go/services/observability v0.7.1 h1:6OObzh2zk7wg75zYstcj0kjOjaxWc4joqA6qdeo8DP4=
588588
github.com/stackitcloud/stackit-sdk-go/services/observability v0.7.1/go.mod h1:+eNo7SEeVRuW7hgujSabSketScSUKGuC88UznPS+UTE=
589-
github.com/stackitcloud/stackit-sdk-go/services/opensearch v0.23.1 h1:E6vCqPn1NiPHnbnvqLNQNz6a/cmeyRb5iA9cDUPtP58=
590-
github.com/stackitcloud/stackit-sdk-go/services/opensearch v0.23.1/go.mod h1:ifKKKCWL1U435fXGQ375SPX+burtfg1I7EGZ58COzRA=
589+
github.com/stackitcloud/stackit-sdk-go/services/opensearch v0.23.0 h1:/OaZCyrD8LFa4W6a2Vu2QSVMJwLLBr8ZdBKzX00MV1Q=
590+
github.com/stackitcloud/stackit-sdk-go/services/opensearch v0.23.0/go.mod h1:c30J6f/fXtbzcHkH3ZcabZUek3wfy5CRnEkcW5e5yXg=
591591
github.com/stackitcloud/stackit-sdk-go/services/postgresflex v1.1.0 h1:r29a9GoBLVw2VZSzdPftlIsE5t7shdxobwoT6NVUIjU=
592592
github.com/stackitcloud/stackit-sdk-go/services/postgresflex v1.1.0/go.mod h1:4g/L5PHfz1xk3udEhvPy2nXiH4UgRO5Cj6iwUa7k5VQ=
593593
github.com/stackitcloud/stackit-sdk-go/services/rabbitmq v0.24.1 h1:2rDFwJtZOFYFUiJqJ9uIwM+mu+BbtuVaUHARRJtrZPU=

0 commit comments

Comments
 (0)