volume

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 3, 2025 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Create

func Create(ctx context.Context, output io.Writer, globalOptions *options.Global, opts *options.VolumeCreate) error

func Inspect

func Inspect(ctx context.Context, output io.Writer, globalOptions *options.Global, opts *options.VolumeInspect) error

func List

func List(ctx context.Context, output io.Writer, globalOptions *options.Global, opts *options.VolumeList) error

func Prune

func Prune(ctx context.Context, client *containerd.Client, output io.Writer, globalOptions *options.Global, opts *options.VolumePrune) error

func Remove

func Remove(ctx context.Context, client *containerd.Client, output io.Writer, globalOptions *options.Global, opts *options.VolumeRemove) error

func Store

func Store(ns string, dataRoot string, address string) (volumestore.VolumeService, error)

Store returns a volume store that corresponds to a directory like `/var/lib/<ROOT_NAME>/1935db59/volumes/default`

func Volumes

func Volumes(ns string, dataRoot string, address string, volumeSize bool, filters []string) (map[string]api.Volume, error)

Volumes returns volumes that match the given filters.

Supported filters:

  • label=<key>=<value>: Match volumes by label on both key and value. If value is left empty, match all volumes with key regardless of its value.
  • name=<value>: Match all volumes with a name containing the value string.
  • size=<value>: Match all volumes with a size meets the value. Size operand can be >=, <=, >, <, = and value must be an integer.

Unsupported filters:

  • dangling=true: Filter volumes by dangling.
  • driver=local: Filter volumes by driver.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL