Documentation ¶
Index ¶
- func Create(ctx context.Context, config entities.VolumeCreateOptions, ...) (*entities.VolumeConfigResponse, error)
- func Exists(ctx context.Context, nameOrID string, options *ExistsOptions) (bool, error)
- func Inspect(ctx context.Context, nameOrID string, options *InspectOptions) (*entities.VolumeConfigResponse, error)
- func List(ctx context.Context, options *ListOptions) ([]*entities.VolumeListReport, error)
- func Prune(ctx context.Context, options *PruneOptions) ([]*reports.PruneReport, error)
- func Remove(ctx context.Context, nameOrID string, options *RemoveOptions) error
- type CreateOptions
- type ExistsOptions
- type InspectOptions
- type ListOptions
- type PruneOptions
- type RemoveOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Create ¶
func Create(ctx context.Context, config entities.VolumeCreateOptions, options *CreateOptions) (*entities.VolumeConfigResponse, error)
Create creates a volume given its configuration.
func Inspect ¶
func Inspect(ctx context.Context, nameOrID string, options *InspectOptions) (*entities.VolumeConfigResponse, error)
Inspect returns low-level information about a volume.
func List ¶
func List(ctx context.Context, options *ListOptions) ([]*entities.VolumeListReport, error)
List returns the configurations for existing volumes in the form of a slice. Optionally, filters can be used to refine the list of volumes.
func Prune ¶
func Prune(ctx context.Context, options *PruneOptions) ([]*reports.PruneReport, error)
Prune removes unused volumes from the local filesystem.
Types ¶
type CreateOptions ¶
type CreateOptions struct { }
CreateOptions are optional options for creating volumes
type ExistsOptions ¶ added in v3.1.0
type ExistsOptions struct { }
ExistsOptions are optional options for checking if a volume exists
func (*ExistsOptions) Changed ¶ added in v3.1.0
func (o *ExistsOptions) Changed(fieldName string) bool
Changed
type InspectOptions ¶
type InspectOptions struct { }
InspectOptions are optional options for inspecting volumes
type ListOptions ¶
type ListOptions struct { // Filters applied to the listing of volumes Filters map[string][]string }
ListOptions are optional options for listing volumes
func (*ListOptions) WithFilters ¶
func (o *ListOptions) WithFilters(value map[string][]string) *ListOptions
WithFilters
type PruneOptions ¶
type PruneOptions struct { // Filters applied to the pruning of volumes Filters map[string][]string }
PruneOptions are optional options for pruning volumes
func (*PruneOptions) GetFilters ¶
func (o *PruneOptions) GetFilters() map[string][]string
GetFilters
func (*PruneOptions) WithFilters ¶
func (o *PruneOptions) WithFilters(value map[string][]string) *PruneOptions
WithFilters
type RemoveOptions ¶
type RemoveOptions struct { // Force removes the volume even if it is being used Force *bool }
RemoveOptions are optional options for removing volumes
func (*RemoveOptions) WithForce ¶
func (o *RemoveOptions) WithForce(value bool) *RemoveOptions
WithForce