openstack

package
v0.56.0 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2019 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthArgs added in v0.47.0

type AuthArgs struct {
	AuthURL    string
	Username   string
	Password   string
	Domain     string
	Region     string
	TenantName string
}

type ComputeAPI added in v0.47.0

type ComputeAPI struct {
	// contains filtered or unexported fields
}

func (ComputeAPI) Delete added in v0.47.0

func (api ComputeAPI) Delete(instanceID string) error

func (ComputeAPI) GetComputeInstancePager added in v0.47.0

func (api ComputeAPI) GetComputeInstancePager() pagination.Pager

func (ComputeAPI) PageToServers added in v0.47.0

func (api ComputeAPI) PageToServers(page pagination.Page) ([]servers.Server, error)

func (ComputeAPI) PagerToPage added in v0.47.0

func (api ComputeAPI) PagerToPage(pager pagination.Pager) (pagination.Page, error)

type ComputeClient added in v0.47.0

type ComputeClient interface {
	List() ([]servers.Server, error)
	Delete(instanceID string) error
}

type ComputeInstance added in v0.47.0

type ComputeInstance struct {
	// contains filtered or unexported fields
}

func NewComputeInstance added in v0.47.0

func NewComputeInstance(name string, id string, computeClient ComputeClient) ComputeInstance

func (ComputeInstance) Delete added in v0.47.0

func (ci ComputeInstance) Delete() error

func (ComputeInstance) Name added in v0.47.0

func (ci ComputeInstance) Name() string

func (ComputeInstance) Type added in v0.47.0

func (ci ComputeInstance) Type() string

type ComputeInstanceAPI added in v0.47.0

type ComputeInstanceAPI interface {
	GetComputeInstancePager() pagination.Pager
	PagerToPage(pagination.Pager) (pagination.Page, error)
	PageToServers(pagination.Page) ([]servers.Server, error)
	Delete(instanceID string) error
}

type ComputeInstanceClient added in v0.47.0

type ComputeInstanceClient struct {
	// contains filtered or unexported fields
}

func NewComputeInstanceClient added in v0.47.0

func NewComputeInstanceClient(api ComputeInstanceAPI) ComputeInstanceClient

func (ComputeInstanceClient) Delete added in v0.47.0

func (client ComputeInstanceClient) Delete(instanceID string) error

func (ComputeInstanceClient) List added in v0.47.0

func (client ComputeInstanceClient) List() ([]servers.Server, error)

type ComputeInstances added in v0.47.0

type ComputeInstances struct {
	// contains filtered or unexported fields
}

func NewComputeInstances added in v0.47.0

func NewComputeInstances(computeClient ComputeClient, logger logger) ComputeInstances

func (ComputeInstances) List added in v0.47.0

func (ci ComputeInstances) List() ([]common.Deletable, error)

func (ComputeInstances) Type added in v0.47.0

func (ci ComputeInstances) Type() string

type Image added in v0.47.0

type Image struct {
	// contains filtered or unexported fields
}

func NewImage added in v0.47.0

func NewImage(name string, id string, imageServiceClient ImageServiceClient) Image

func (Image) Delete added in v0.47.0

func (image Image) Delete() error

func (Image) Name added in v0.47.0

func (image Image) Name() string

func (Image) Type added in v0.47.0

func (image Image) Type() string

type ImageAPI added in v0.47.0

type ImageAPI struct {
	// contains filtered or unexported fields
}

func (ImageAPI) Delete added in v0.47.0

func (api ImageAPI) Delete(imageID string) error

func (ImageAPI) GetImagesPager added in v0.47.0

func (api ImageAPI) GetImagesPager() pagination.Pager

func (ImageAPI) PageToImages added in v0.47.0

func (api ImageAPI) PageToImages(page pagination.Page) ([]images.Image, error)

func (ImageAPI) PagerToPage added in v0.47.0

func (api ImageAPI) PagerToPage(pager pagination.Pager) (pagination.Page, error)

type ImageServiceClient added in v0.47.0

type ImageServiceClient interface {
	List() ([]images.Image, error)
	Delete(imageID string) error
}

type Images added in v0.47.0

type Images struct {
	// contains filtered or unexported fields
}

func NewImages added in v0.47.0

func NewImages(imageServiceClient ImageServiceClient, logger logger) Images

func (Images) List added in v0.47.0

func (images Images) List() ([]common.Deletable, error)

func (Images) Type added in v0.47.0

func (images Images) Type() string

type ImagesClient added in v0.47.0

type ImagesClient struct {
	// contains filtered or unexported fields
}

func NewImagesClient added in v0.47.0

func NewImagesClient(imageAPI imageAPI) ImagesClient

func (ImagesClient) Delete added in v0.47.0

func (ic ImagesClient) Delete(imageID string) error

func (ImagesClient) List added in v0.47.0

func (ic ImagesClient) List() ([]images.Image, error)

type Leftovers

type Leftovers struct {
	// contains filtered or unexported fields
}

func NewLeftovers

func NewLeftovers(logger logger, authArgs AuthArgs) (Leftovers, error)

NewLeftovers returns a new Leftovers for OpenStack that can be used to list resources, list types, or delete resources for the provided account. It returns an error if the credentials provided are invalid or if a client fails to be created.

func (Leftovers) Delete

func (l Leftovers) Delete(filter string) error

Delete will collect all resources that contain the provided filter in the resource's identifier, prompt you to confirm deletion (if enabled), and delete thoseu that are selected.

func (Leftovers) DeleteByType added in v0.55.0

func (l Leftovers) DeleteByType(filter, rType string) error

DeleteByType will collect all resources of the provied type that contain the provided filter in the resource's identifier, prompt you to confirm deletion (if enabled), and delete those that are selected.

func (Leftovers) List

func (l Leftovers) List(filter string)

List will print all of the resources that match the provided filter.

func (Leftovers) ListByType added in v0.55.0

func (l Leftovers) ListByType(filter, rType string)

ListByType defaults to List.

func (Leftovers) Types

func (l Leftovers) Types()

Types will print all the resource types that can be deleted on this IaaS.

type Volume added in v0.47.0

type Volume struct {
	// contains filtered or unexported fields
}

func NewVolume added in v0.47.0

func NewVolume(name string, id string, volumesClient VolumesClient) Volume

func (Volume) Delete added in v0.47.0

func (volume Volume) Delete() error

func (Volume) Name added in v0.47.0

func (volume Volume) Name() string

func (Volume) Type added in v0.47.0

func (volume Volume) Type() string

type Volumes added in v0.47.0

type Volumes struct {
	// contains filtered or unexported fields
}

func NewVolumes added in v0.47.0

func NewVolumes(volumesClient VolumesClient, logger logger) Volumes

func (Volumes) List added in v0.47.0

func (volumes Volumes) List() ([]common.Deletable, error)

func (Volumes) Type added in v0.47.0

func (volumes Volumes) Type() string

type VolumesAPI added in v0.47.0

type VolumesAPI struct {
	// contains filtered or unexported fields
}

func (VolumesAPI) DeleteVolume added in v0.47.0

func (api VolumesAPI) DeleteVolume(id string) error

func (VolumesAPI) GetVolumesPager added in v0.47.0

func (api VolumesAPI) GetVolumesPager() pagination.Pager

func (VolumesAPI) PageToVolumes added in v0.47.0

func (api VolumesAPI) PageToVolumes(page pagination.Page) ([]volumes.Volume, error)

func (VolumesAPI) PagerToPage added in v0.47.0

func (api VolumesAPI) PagerToPage(pager pagination.Pager) (pagination.Page, error)

type VolumesBlockStorageClient added in v0.47.0

type VolumesBlockStorageClient struct {
	// contains filtered or unexported fields
}

func NewVolumesBlockStorageClient added in v0.47.0

func NewVolumesBlockStorageClient(volumesAPI volumesAPI) VolumesBlockStorageClient

func (VolumesBlockStorageClient) Delete added in v0.47.0

func (vs VolumesBlockStorageClient) Delete(volumeID string) error

func (VolumesBlockStorageClient) List added in v0.47.0

type VolumesClient added in v0.47.0

type VolumesClient interface {
	List() ([]volumes.Volume, error)
	Delete(volumeID string) error
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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