Skip to content

Commit

Permalink
csi: document updates for snapshot list
Browse files Browse the repository at this point in the history
  • Loading branch information
tgross committed Mar 4, 2022
1 parent bdd5bd7 commit d4673a8
Showing 1 changed file with 9 additions and 13 deletions.
22 changes: 9 additions & 13 deletions website/content/docs/commands/volume/snapshot-list.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -15,28 +15,24 @@ command.
## Usage

```plaintext
nomad volume snapshot list [-plugin plugin_id -secrets key=value]
nomad volume snapshot list <plugin_id> -secrets key=value]
```

The `volume snapshot list` command returns a list of snapshots along with their
source volume ID as known to the external storage provider. This is not the
same as the Nomad volume ID, as the source volume may not be [registered] with
Nomad.
The `volume snapshot list` command returns a list of snapshots for a
plugin along with their source volume ID as known to the external
storage provider. This is not the same as the Nomad volume ID, as the
source volume may not be [registered] with Nomad.

## General Options

@include 'general_options.mdx'

## Snapshot List Options

- `-plugin`: Display only snapshots managed by a particular [CSI
plugin][csi_plugin]. By default the `snapshot list` command will query all
plugins for their snapshots. This flag accepts a plugin ID or prefix. If
there is an exact match based on the provided plugin, then that specific
plugin will be queried. Otherwise, a list of matching plugins will be
displayed.
- `-secret`: Secrets to pass to the plugin to list snapshots. Accepts
multiple flags in the form `-secret key=value`
- `-per-page`: How many results to show per page.
- `-page-token`: Where to start pagination.

When ACLs are enabled, this command requires a token with the
`csi-list-volumes` capability for the plugin's namespace.
Expand All @@ -46,15 +42,15 @@ When ACLs are enabled, this command requires a token with the
List volume snapshots for a plugin:

```shell-session
$ nomad volume snapshot list -plugin aws-ebs0
$ nomad volume snapshot list aws-ebs0
Snapshot ID External ID Size Creation Time Ready?
snap-12345 vol-abcdef 50GiB 2021-01-03T12:15:02Z true
snap-67890 vol-fedcba 50GiB 2021-01-04T15:45:00Z true
```

List volume snapshots with two secret key/value pairs:
```shell-session
$ nomad volume snapshot list -secret key1=value1 -secret key2=val2
$ nomad volume snapshot list aws-ebs0 -secret key1=value1 -secret key2=val2
Snapshot ID External ID Size Creation Time Ready?
snap-12345 vol-abcdef 50GiB 2021-01-03T12:15:02Z true
```
Expand Down

0 comments on commit d4673a8

Please sign in to comment.