Documentation ¶
Index ¶
- Constants
- Variables
- type Config
- type Instances
- func (i *Instances) AddSSHKeyToAllInstances(user string, keyData []byte) error
- func (i *Instances) CurrentNodeName(hostname string) (string, error)
- func (i *Instances) ExternalID(name string) (string, error)
- func (i *Instances) InstanceID(name string) (string, error)
- func (i *Instances) InstanceType(name string) (string, error)
- func (i *Instances) List(name_filter string) ([]string, error)
- func (i *Instances) NodeAddresses(name string) ([]api.NodeAddress, error)
- type LoadBalancer
- func (lb *LoadBalancer) EnsureLoadBalancer(apiService *api.Service, hosts []string, annotations map[string]string) (*api.LoadBalancerStatus, error)
- func (lb *LoadBalancer) EnsureLoadBalancerDeleted(service *api.Service) error
- func (lb *LoadBalancer) GetLoadBalancer(service *api.Service) (*api.LoadBalancerStatus, bool, error)
- func (lb *LoadBalancer) UpdateLoadBalancer(service *api.Service, hosts []string) error
- type LoadBalancerOpts
- type MyDuration
- type OpenStack
- func (os *OpenStack) AttachDisk(diskName string) (string, error)
- func (os *OpenStack) Clusters() (cloudprovider.Clusters, bool)
- func (os *OpenStack) CreateVolume(name string, size int, tags *map[string]string) (volumeName string, err error)
- func (os *OpenStack) DeleteVolume(volumeName string) error
- func (os *OpenStack) DetachDisk(partialDiskId string) error
- func (os *OpenStack) GetZone() (cloudprovider.Zone, error)
- func (os *OpenStack) Instances() (cloudprovider.Instances, bool)
- func (os *OpenStack) LoadBalancer() (cloudprovider.LoadBalancer, bool)
- func (os *OpenStack) ProviderName() string
- func (os *OpenStack) Routes() (cloudprovider.Routes, bool)
- func (os *OpenStack) ScrubDNS(nameservers, searches []string) (nsOut, srchOut []string)
- func (os *OpenStack) Zones() (cloudprovider.Zones, bool)
Constants ¶
View Source
const ( MiB = 1024 * 1024 GB = 1000 * 1000 * 1000 )
View Source
const ProviderName = "openstack"
Variables ¶
View Source
var ErrAttrNotFound = errors.New("Expected attribute not found")
View Source
var ErrMultipleResults = errors.New("Multiple results where only one expected")
View Source
var ErrNoAddressFound = errors.New("No address found for host")
View Source
var ErrNotFound = errors.New("Failed to find object")
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Global struct { AuthUrl string `gcfg:"auth-url"` Username string UserId string `gcfg:"user-id"` Password string ApiKey string `gcfg:"api-key"` TenantId string `gcfg:"tenant-id"` TenantName string `gcfg:"tenant-name"` DomainId string `gcfg:"domain-id"` DomainName string `gcfg:"domain-name"` Region string } LoadBalancer LoadBalancerOpts }
type Instances ¶
type Instances struct {
// contains filtered or unexported fields
}
func (*Instances) AddSSHKeyToAllInstances ¶
func (*Instances) CurrentNodeName ¶
Implementation of Instances.CurrentNodeName
func (*Instances) ExternalID ¶
ExternalID returns the cloud provider ID of the specified instance (deprecated).
func (*Instances) InstanceID ¶
InstanceID returns the cloud provider ID of the specified instance.
func (*Instances) InstanceType ¶ added in v1.2.0
InstanceType returns the type of the specified instance.
func (*Instances) NodeAddresses ¶
func (i *Instances) NodeAddresses(name string) ([]api.NodeAddress, error)
type LoadBalancer ¶
type LoadBalancer struct {
// contains filtered or unexported fields
}
func (*LoadBalancer) EnsureLoadBalancer ¶ added in v1.2.0
func (lb *LoadBalancer) EnsureLoadBalancer(apiService *api.Service, hosts []string, annotations map[string]string) (*api.LoadBalancerStatus, error)
func (*LoadBalancer) EnsureLoadBalancerDeleted ¶ added in v1.2.0
func (lb *LoadBalancer) EnsureLoadBalancerDeleted(service *api.Service) error
func (*LoadBalancer) GetLoadBalancer ¶ added in v1.2.0
func (lb *LoadBalancer) GetLoadBalancer(service *api.Service) (*api.LoadBalancerStatus, bool, error)
func (*LoadBalancer) UpdateLoadBalancer ¶ added in v1.2.0
func (lb *LoadBalancer) UpdateLoadBalancer(service *api.Service, hosts []string) error
type LoadBalancerOpts ¶
type LoadBalancerOpts struct { SubnetId string `gcfg:"subnet-id"` // required FloatingNetworkId string `gcfg:"floating-network-id"` LBMethod string `gcfg:"lb-method"` CreateMonitor bool `gcfg:"create-monitor"` MonitorDelay MyDuration `gcfg:"monitor-delay"` MonitorTimeout MyDuration `gcfg:"monitor-timeout"` MonitorMaxRetries uint `gcfg:"monitor-max-retries"` }
type MyDuration ¶
encoding.TextUnmarshaler interface for time.Duration
func (*MyDuration) UnmarshalText ¶
func (d *MyDuration) UnmarshalText(text []byte) error
type OpenStack ¶
type OpenStack struct {
// contains filtered or unexported fields
}
OpenStack is an implementation of cloud provider Interface for OpenStack.
func (*OpenStack) AttachDisk ¶
Attaches given cinder volume to the compute running kubelet
func (*OpenStack) CreateVolume ¶ added in v1.2.0
func (os *OpenStack) CreateVolume(name string, size int, tags *map[string]string) (volumeName string, err error)
Create a volume of given size (in GiB)
func (*OpenStack) DeleteVolume ¶ added in v1.2.0
func (*OpenStack) DetachDisk ¶
Detaches given cinder volume from the compute running kubelet
func (*OpenStack) Instances ¶
func (os *OpenStack) Instances() (cloudprovider.Instances, bool)
Instances returns an implementation of Instances for OpenStack.
func (*OpenStack) LoadBalancer ¶ added in v1.2.0
func (os *OpenStack) LoadBalancer() (cloudprovider.LoadBalancer, bool)
func (*OpenStack) ProviderName ¶
ProviderName returns the cloud provider ID.
Click to show internal directories.
Click to hide internal directories.