Documentation
¶
Index ¶
- type AuthOptions
- type Client
- func (c *Client) Build(params map[string]interface{}) (api.ClientAPI, error)
- func (client *Client) CreateVolume(request model.VolumeRequest) (*model.Volume, error)
- func (client *Client) CreateVolumeAttachment(request model.VolumeAttachmentRequest) (string, error)
- func (client *Client) DeleteVolume(id string) error
- func (client *Client) DeleteVolumeAttachment(serverID, vaID string) error
- func (client *Client) GetVolume(id string) (*model.Volume, error)
- func (client *Client) GetVolumeAttachment(serverID, id string) (*model.VolumeAttachment, error)
- func (client *Client) ListVolumeAttachments(serverID string) ([]model.VolumeAttachment, error)
- func (client *Client) ListVolumes() ([]model.Volume, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuthOptions ¶
type AuthOptions struct {
Username string
Password string
TenantName string
Region string
DomainName string
ProjectName string
ProjectID string
}
AuthOptions fields are the union of those recognized by each identity implementation and provider.
type Client ¶
Client is the implementation of the ovh driver regarding to the api.ClientAPI This client used ovh api and opensatck ovh api to maximize code reuse
func AuthenticatedClient ¶
func AuthenticatedClient(opts AuthOptions, cfg openstack.CfgOptions) (*Client, error)
AuthenticatedClient returns an authenticated client
func (*Client) CreateVolume ¶
CreateVolume creates a block volume - name is the name of the volume - size is the size of the volume in GB - volumeType is the type of volume to create, if volumeType is empty the driver use a default type
func (*Client) CreateVolumeAttachment ¶
func (client *Client) CreateVolumeAttachment(request model.VolumeAttachmentRequest) (string, error)
CreateVolumeAttachment attaches a volume to an host - 'name' of the volume attachment - 'volume' to attach - 'host' on which the volume is attached
func (*Client) DeleteVolume ¶
DeleteVolume deletes the volume identified by id
func (*Client) DeleteVolumeAttachment ¶
DeleteVolumeAttachment deletes the volume attachment identifed by id
func (*Client) GetVolumeAttachment ¶
func (client *Client) GetVolumeAttachment(serverID, id string) (*model.VolumeAttachment, error)
GetVolumeAttachment returns the volume attachment identified by id
func (*Client) ListVolumeAttachments ¶
func (client *Client) ListVolumeAttachments(serverID string) ([]model.VolumeAttachment, error)
ListVolumeAttachments lists available volume attachment