Documentation ¶
Index ¶
- type Capabilities
- type Config
- type ConfigMap
- func (c ConfigMap) Config(name string) (interface{}, bool)
- func (c ConfigMap) Get(name string) (interface{}, bool)
- func (c ConfigMap) GetInteger(name string) int
- func (c ConfigMap) GetMapOfStrings(name string) map[string]string
- func (c ConfigMap) GetSliceOfStrings(name string) []string
- func (c ConfigMap) GetString(name string) string
- func (c ConfigMap) Set(name string, value interface{})
- type Provider
- type ProviderProxy
- func (s ProviderProxy) AddPublicIPToVIP(ip *abstract.VirtualIP) (ferr fail.Error)
- func (s ProviderProxy) AddRuleToSecurityGroup(sgParam stacks.SecurityGroupParameter, rule *abstract.SecurityGroupRule) (_ *abstract.SecurityGroup, ferr fail.Error)
- func (s ProviderProxy) BindHostToVIP(ip *abstract.VirtualIP, s2 string) (ferr fail.Error)
- func (s ProviderProxy) BindSecurityGroupToHost(sgParam stacks.SecurityGroupParameter, hostParam stacks.HostParameter) (ferr fail.Error)
- func (s ProviderProxy) BindSecurityGroupToSubnet(sgParam stacks.SecurityGroupParameter, subnetID string) (ferr fail.Error)
- func (s ProviderProxy) Build(m map[string]interface{}) (_ Provider, ferr fail.Error)
- func (s ProviderProxy) ClearHostStartupScript(parameter stacks.HostParameter) (ferr fail.Error)
- func (s ProviderProxy) ClearSecurityGroup(sgParam stacks.SecurityGroupParameter) (_ *abstract.SecurityGroup, ferr fail.Error)
- func (s ProviderProxy) CreateHost(request abstract.HostRequest) (_ *abstract.HostFull, _ *userdata.Content, ferr fail.Error)
- func (s ProviderProxy) CreateKeyPair(name string) (_ *abstract.KeyPair, ferr fail.Error)
- func (s ProviderProxy) CreateNetwork(req abstract.NetworkRequest) (_ *abstract.Network, ferr fail.Error)
- func (s ProviderProxy) CreateSecurityGroup(networkRef, name, description string, rules abstract.SecurityGroupRules) (_ *abstract.SecurityGroup, ferr fail.Error)
- func (s ProviderProxy) CreateSubnet(req abstract.SubnetRequest) (_ *abstract.Subnet, ferr fail.Error)
- func (s ProviderProxy) CreateVIP(networkID, subnetID, name string, securityGroups []string) (_ *abstract.VirtualIP, ferr fail.Error)
- func (s ProviderProxy) CreateVolume(request abstract.VolumeRequest) (_ *abstract.Volume, ferr fail.Error)
- func (s ProviderProxy) CreateVolumeAttachment(request abstract.VolumeAttachmentRequest) (_ string, ferr fail.Error)
- func (s ProviderProxy) DeleteHost(parameter stacks.HostParameter) (ferr fail.Error)
- func (s ProviderProxy) DeleteKeyPair(id string) (ferr fail.Error)
- func (s ProviderProxy) DeleteNetwork(id string) (ferr fail.Error)
- func (s ProviderProxy) DeleteRuleFromSecurityGroup(sgParam stacks.SecurityGroupParameter, rule *abstract.SecurityGroupRule) (_ *abstract.SecurityGroup, ferr fail.Error)
- func (s ProviderProxy) DeleteSecurityGroup(group *abstract.SecurityGroup) (ferr fail.Error)
- func (s ProviderProxy) DeleteSubnet(id string) (ferr fail.Error)
- func (s ProviderProxy) DeleteVIP(ip *abstract.VirtualIP) (ferr fail.Error)
- func (s ProviderProxy) DeleteVolume(id string) (ferr fail.Error)
- func (s ProviderProxy) DeleteVolumeAttachment(serverID, id string) (ferr fail.Error)
- func (s ProviderProxy) DisableSecurityGroup(group *abstract.SecurityGroup) (ferr fail.Error)
- func (s ProviderProxy) EnableSecurityGroup(group *abstract.SecurityGroup) (ferr fail.Error)
- func (s ProviderProxy) GetAuthenticationOptions() (_ Config, ferr fail.Error)
- func (s ProviderProxy) GetCapabilities() (_ Capabilities, ferr fail.Error)
- func (s ProviderProxy) GetConfigurationOptions() (_ Config, ferr fail.Error)
- func (s ProviderProxy) GetDefaultNetwork() (_ *abstract.Network, ferr fail.Error)
- func (s ProviderProxy) GetDefaultSecurityGroupName() (_ string, ferr fail.Error)
- func (s ProviderProxy) GetHostState(parameter stacks.HostParameter) (_ hoststate.Enum, ferr fail.Error)
- func (s ProviderProxy) GetName() (_ string, ferr fail.Error)
- func (s ProviderProxy) GetRawAuthenticationOptions() (_ stacks.AuthenticationOptions, ferr fail.Error)
- func (s ProviderProxy) GetRawConfigurationOptions() (_ stacks.ConfigurationOptions, ferr fail.Error)
- func (s ProviderProxy) GetRegexpsOfTemplatesWithGPU() (_ []*regexp.Regexp, ferr fail.Error)
- func (s ProviderProxy) GetStack() (_ api.Stack, ferr fail.Error)
- func (s ProviderProxy) GetStackName() (_ string, ferr fail.Error)
- func (s ProviderProxy) GetTenantParameters() (_ map[string]interface{}, ferr fail.Error)
- func (s ProviderProxy) HasDefaultNetwork() (_ bool, ferr fail.Error)
- func (s ProviderProxy) InspectHost(parameter stacks.HostParameter) (_ *abstract.HostFull, ferr fail.Error)
- func (s ProviderProxy) InspectImage(id string) (_ *abstract.Image, ferr fail.Error)
- func (s ProviderProxy) InspectKeyPair(id string) (_ *abstract.KeyPair, ferr fail.Error)
- func (s ProviderProxy) InspectNetwork(id string) (_ *abstract.Network, ferr fail.Error)
- func (s ProviderProxy) InspectNetworkByName(name string) (_ *abstract.Network, ferr fail.Error)
- func (s ProviderProxy) InspectSecurityGroup(sgParam stacks.SecurityGroupParameter) (_ *abstract.SecurityGroup, ferr fail.Error)
- func (s ProviderProxy) InspectSubnet(id string) (_ *abstract.Subnet, ferr fail.Error)
- func (s ProviderProxy) InspectSubnetByName(networkID, name string) (_ *abstract.Subnet, ferr fail.Error)
- func (s ProviderProxy) InspectTemplate(id string) (_ *abstract.HostTemplate, ferr fail.Error)
- func (s ProviderProxy) InspectVolume(id string) (_ *abstract.Volume, ferr fail.Error)
- func (s ProviderProxy) InspectVolumeAttachment(serverID, id string) (_ *abstract.VolumeAttachment, ferr fail.Error)
- func (s ProviderProxy) ListAvailabilityZones() (_ map[string]bool, ferr fail.Error)
- func (s ProviderProxy) ListHosts(b bool) (_ abstract.HostList, ferr fail.Error)
- func (s ProviderProxy) ListImages(all bool) (_ []*abstract.Image, ferr fail.Error)
- func (s ProviderProxy) ListKeyPairs() (_ []*abstract.KeyPair, ferr fail.Error)
- func (s ProviderProxy) ListNetworks() (_ []*abstract.Network, ferr fail.Error)
- func (s ProviderProxy) ListRegions() (_ []string, ferr fail.Error)
- func (s ProviderProxy) ListSecurityGroups(networkRef string) (_ []*abstract.SecurityGroup, ferr fail.Error)
- func (s ProviderProxy) ListSubnets(networkID string) (_ []*abstract.Subnet, ferr fail.Error)
- func (s ProviderProxy) ListTemplates(all bool) (_ []*abstract.HostTemplate, ferr fail.Error)
- func (s ProviderProxy) ListVolumeAttachments(serverID string) (_ []*abstract.VolumeAttachment, ferr fail.Error)
- func (s ProviderProxy) ListVolumes() (_ []*abstract.Volume, ferr fail.Error)
- func (s ProviderProxy) Migrate(operation string, params map[string]interface{}) (ferr fail.Error)
- func (s ProviderProxy) RebootHost(parameter stacks.HostParameter) (ferr fail.Error)
- func (s ProviderProxy) ResizeHost(parameter stacks.HostParameter, requirements abstract.HostSizingRequirements) (_ *abstract.HostFull, ferr fail.Error)
- func (s ProviderProxy) StartHost(parameter stacks.HostParameter) (ferr fail.Error)
- func (s ProviderProxy) StopHost(host stacks.HostParameter, gracefully bool) (ferr fail.Error)
- func (s ProviderProxy) UnbindHostFromVIP(ip *abstract.VirtualIP, s2 string) (ferr fail.Error)
- func (s ProviderProxy) UnbindSecurityGroupFromHost(sgParam stacks.SecurityGroupParameter, hostParam stacks.HostParameter) (ferr fail.Error)
- func (s ProviderProxy) UnbindSecurityGroupFromSubnet(sgParam stacks.SecurityGroupParameter, subnetID string) (ferr fail.Error)
- func (s ProviderProxy) WaitHostReady(hostParam stacks.HostParameter, timeout time.Duration) (_ *abstract.HostCore, ferr fail.Error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Capabilities ¶
type Capabilities struct { // PublicVirtualIP indicates if the provider has the capability to provide a Virtual IP with public IP address PublicVirtualIP bool // PrivateVirtualIP indicates if the provider has the capability to provide a Virtual IP with private IP address PrivateVirtualIP bool // Layer3Networking indicates if the provider uses Layer3 networking Layer3Networking bool // CanDisableSecurityGroup indicates if the provider supports to disable a Security Group CanDisableSecurityGroup bool }
Capabilities represents key/value configuration.
type Config ¶
type Config interface { // Config gets a string configuration value and a // bool indicating whether the value was present or not. Config(name string) (interface{}, bool) // Get is an alias to Config() Get(name string) (interface{}, bool) // Set sets the configuration name to specified value Set(name string, value interface{}) // GetString returns a string corresponding to the key, empty string if it doesn't exist GetString(name string) string // GetSliceOfStrings returns a slice of strings corresponding to the key, empty string slice if it doesn't exist GetSliceOfStrings(name string) []string // GetMapOfStrings returns a string map of strings corresponding to the key, empty map if it doesn't exist GetMapOfStrings(name string) map[string]string // GetInteger returns an integer corresponding to the key, 0 if it doesn't exist GetInteger(name string) int }
Config represents key/value configuration.
type ConfigMap ¶
type ConfigMap map[string]interface{}
ConfigMap is a map[string]string that implements the Config method.
func (ConfigMap) Config ¶
Config gets a string configuration value and a bool indicating whether the value was present or not.
func (ConfigMap) GetInteger ¶
GetInteger returns an integer corresponding to the key, 0 if it doesn't exist
func (ConfigMap) GetMapOfStrings ¶
GetMapOfStrings returns a string map of strings corresponding to the key, empty map if it doesn't exist
func (ConfigMap) GetSliceOfStrings ¶
GetSliceOfStrings returns a string slice corresponding to the key, empty string slice if it doesn't exist
type Provider ¶
type Provider interface { api.Stack // Build builds a new Client from configuration parameter and can be called from nil Build(map[string]interface{}) (Provider, fail.Error) // ListImages lists available OS images, all bool is unused here but used at upper levels to filter using whitelists and blacklists ListImages(all bool) ([]*abstract.Image, fail.Error) // ListTemplates lists available host templates, all bool is unused here but used at upper levels to filter using whitelists and blacklists, Host templates are sorted using Dominant Resource Fairness Algorithm ListTemplates(all bool) ([]*abstract.HostTemplate, fail.Error) // GetAuthenticationOptions returns authentication options as a Config GetAuthenticationOptions() (Config, fail.Error) // GetConfigurationOptions returns configuration options as a Config GetConfigurationOptions() (Config, fail.Error) GetName() (string, fail.Error) // GetName returns the tenant name GetStack() (api.Stack, fail.Error) // Returns the stack object used by the provider. Use with caution GetRegexpsOfTemplatesWithGPU() ([]*regexp.Regexp, fail.Error) // GetCapabilities returns the capabilities of the provider GetCapabilities() (Capabilities, fail.Error) // GetTenantParameters returns the tenant parameters as read GetTenantParameters() (map[string]interface{}, fail.Error) }
Provider is the interface to cloud stack It has to recall Stack api, to serve as Provider AND as Stack
type ProviderProxy ¶
ProviderProxy ...
func (ProviderProxy) AddPublicIPToVIP ¶
func (s ProviderProxy) AddPublicIPToVIP(ip *abstract.VirtualIP) (ferr fail.Error)
func (ProviderProxy) AddRuleToSecurityGroup ¶
func (s ProviderProxy) AddRuleToSecurityGroup(sgParam stacks.SecurityGroupParameter, rule *abstract.SecurityGroupRule) (_ *abstract.SecurityGroup, ferr fail.Error)
func (ProviderProxy) BindHostToVIP ¶
func (ProviderProxy) BindSecurityGroupToHost ¶
func (s ProviderProxy) BindSecurityGroupToHost(sgParam stacks.SecurityGroupParameter, hostParam stacks.HostParameter) (ferr fail.Error)
func (ProviderProxy) BindSecurityGroupToSubnet ¶
func (s ProviderProxy) BindSecurityGroupToSubnet(sgParam stacks.SecurityGroupParameter, subnetID string) (ferr fail.Error)
func (ProviderProxy) Build ¶
func (s ProviderProxy) Build(m map[string]interface{}) (_ Provider, ferr fail.Error)
func (ProviderProxy) ClearHostStartupScript ¶
func (s ProviderProxy) ClearHostStartupScript(parameter stacks.HostParameter) (ferr fail.Error)
func (ProviderProxy) ClearSecurityGroup ¶
func (s ProviderProxy) ClearSecurityGroup(sgParam stacks.SecurityGroupParameter) (_ *abstract.SecurityGroup, ferr fail.Error)
func (ProviderProxy) CreateHost ¶
func (s ProviderProxy) CreateHost(request abstract.HostRequest) (_ *abstract.HostFull, _ *userdata.Content, ferr fail.Error)
func (ProviderProxy) CreateKeyPair ¶
func (ProviderProxy) CreateNetwork ¶
func (s ProviderProxy) CreateNetwork(req abstract.NetworkRequest) (_ *abstract.Network, ferr fail.Error)
func (ProviderProxy) CreateSecurityGroup ¶
func (s ProviderProxy) CreateSecurityGroup(networkRef, name, description string, rules abstract.SecurityGroupRules) (_ *abstract.SecurityGroup, ferr fail.Error)
func (ProviderProxy) CreateSubnet ¶
func (s ProviderProxy) CreateSubnet(req abstract.SubnetRequest) (_ *abstract.Subnet, ferr fail.Error)
func (ProviderProxy) CreateVolume ¶
func (s ProviderProxy) CreateVolume(request abstract.VolumeRequest) (_ *abstract.Volume, ferr fail.Error)
func (ProviderProxy) CreateVolumeAttachment ¶
func (s ProviderProxy) CreateVolumeAttachment(request abstract.VolumeAttachmentRequest) (_ string, ferr fail.Error)
func (ProviderProxy) DeleteHost ¶
func (s ProviderProxy) DeleteHost(parameter stacks.HostParameter) (ferr fail.Error)
func (ProviderProxy) DeleteKeyPair ¶
func (s ProviderProxy) DeleteKeyPair(id string) (ferr fail.Error)
func (ProviderProxy) DeleteNetwork ¶
func (s ProviderProxy) DeleteNetwork(id string) (ferr fail.Error)
func (ProviderProxy) DeleteRuleFromSecurityGroup ¶
func (s ProviderProxy) DeleteRuleFromSecurityGroup(sgParam stacks.SecurityGroupParameter, rule *abstract.SecurityGroupRule) (_ *abstract.SecurityGroup, ferr fail.Error)
func (ProviderProxy) DeleteSecurityGroup ¶
func (s ProviderProxy) DeleteSecurityGroup(group *abstract.SecurityGroup) (ferr fail.Error)
func (ProviderProxy) DeleteSubnet ¶
func (s ProviderProxy) DeleteSubnet(id string) (ferr fail.Error)
func (ProviderProxy) DeleteVIP ¶
func (s ProviderProxy) DeleteVIP(ip *abstract.VirtualIP) (ferr fail.Error)
func (ProviderProxy) DeleteVolume ¶
func (s ProviderProxy) DeleteVolume(id string) (ferr fail.Error)
func (ProviderProxy) DeleteVolumeAttachment ¶
func (s ProviderProxy) DeleteVolumeAttachment(serverID, id string) (ferr fail.Error)
func (ProviderProxy) DisableSecurityGroup ¶
func (s ProviderProxy) DisableSecurityGroup(group *abstract.SecurityGroup) (ferr fail.Error)
func (ProviderProxy) EnableSecurityGroup ¶
func (s ProviderProxy) EnableSecurityGroup(group *abstract.SecurityGroup) (ferr fail.Error)
func (ProviderProxy) GetAuthenticationOptions ¶
func (s ProviderProxy) GetAuthenticationOptions() (_ Config, ferr fail.Error)
func (ProviderProxy) GetCapabilities ¶
func (s ProviderProxy) GetCapabilities() (_ Capabilities, ferr fail.Error)
func (ProviderProxy) GetConfigurationOptions ¶
func (s ProviderProxy) GetConfigurationOptions() (_ Config, ferr fail.Error)
func (ProviderProxy) GetDefaultNetwork ¶
func (s ProviderProxy) GetDefaultNetwork() (_ *abstract.Network, ferr fail.Error)
func (ProviderProxy) GetDefaultSecurityGroupName ¶
func (s ProviderProxy) GetDefaultSecurityGroupName() (_ string, ferr fail.Error)
func (ProviderProxy) GetHostState ¶
func (s ProviderProxy) GetHostState(parameter stacks.HostParameter) (_ hoststate.Enum, ferr fail.Error)
func (ProviderProxy) GetRawAuthenticationOptions ¶
func (s ProviderProxy) GetRawAuthenticationOptions() (_ stacks.AuthenticationOptions, ferr fail.Error)
func (ProviderProxy) GetRawConfigurationOptions ¶
func (s ProviderProxy) GetRawConfigurationOptions() (_ stacks.ConfigurationOptions, ferr fail.Error)
func (ProviderProxy) GetRegexpsOfTemplatesWithGPU ¶
func (s ProviderProxy) GetRegexpsOfTemplatesWithGPU() (_ []*regexp.Regexp, ferr fail.Error)
func (ProviderProxy) GetStackName ¶
func (s ProviderProxy) GetStackName() (_ string, ferr fail.Error)
func (ProviderProxy) GetTenantParameters ¶
func (s ProviderProxy) GetTenantParameters() (_ map[string]interface{}, ferr fail.Error)
func (ProviderProxy) HasDefaultNetwork ¶
func (s ProviderProxy) HasDefaultNetwork() (_ bool, ferr fail.Error)
func (ProviderProxy) InspectHost ¶
func (s ProviderProxy) InspectHost(parameter stacks.HostParameter) (_ *abstract.HostFull, ferr fail.Error)
func (ProviderProxy) InspectImage ¶
func (ProviderProxy) InspectKeyPair ¶
func (ProviderProxy) InspectNetwork ¶
func (ProviderProxy) InspectNetworkByName ¶
func (ProviderProxy) InspectSecurityGroup ¶
func (s ProviderProxy) InspectSecurityGroup(sgParam stacks.SecurityGroupParameter) (_ *abstract.SecurityGroup, ferr fail.Error)
func (ProviderProxy) InspectSubnet ¶
func (ProviderProxy) InspectSubnetByName ¶
func (ProviderProxy) InspectTemplate ¶
func (s ProviderProxy) InspectTemplate(id string) (_ *abstract.HostTemplate, ferr fail.Error)
func (ProviderProxy) InspectVolume ¶
func (ProviderProxy) InspectVolumeAttachment ¶
func (s ProviderProxy) InspectVolumeAttachment(serverID, id string) (_ *abstract.VolumeAttachment, ferr fail.Error)
func (ProviderProxy) ListAvailabilityZones ¶
func (s ProviderProxy) ListAvailabilityZones() (_ map[string]bool, ferr fail.Error)
func (ProviderProxy) ListImages ¶
func (ProviderProxy) ListKeyPairs ¶
func (s ProviderProxy) ListKeyPairs() (_ []*abstract.KeyPair, ferr fail.Error)
func (ProviderProxy) ListNetworks ¶
func (s ProviderProxy) ListNetworks() (_ []*abstract.Network, ferr fail.Error)
func (ProviderProxy) ListRegions ¶
func (s ProviderProxy) ListRegions() (_ []string, ferr fail.Error)
func (ProviderProxy) ListSecurityGroups ¶
func (s ProviderProxy) ListSecurityGroups(networkRef string) (_ []*abstract.SecurityGroup, ferr fail.Error)
func (ProviderProxy) ListSubnets ¶
func (ProviderProxy) ListTemplates ¶
func (s ProviderProxy) ListTemplates(all bool) (_ []*abstract.HostTemplate, ferr fail.Error)
func (ProviderProxy) ListVolumeAttachments ¶
func (s ProviderProxy) ListVolumeAttachments(serverID string) (_ []*abstract.VolumeAttachment, ferr fail.Error)
func (ProviderProxy) ListVolumes ¶
func (s ProviderProxy) ListVolumes() (_ []*abstract.Volume, ferr fail.Error)
func (ProviderProxy) Migrate ¶
func (s ProviderProxy) Migrate(operation string, params map[string]interface{}) (ferr fail.Error)
func (ProviderProxy) RebootHost ¶
func (s ProviderProxy) RebootHost(parameter stacks.HostParameter) (ferr fail.Error)
func (ProviderProxy) ResizeHost ¶
func (s ProviderProxy) ResizeHost(parameter stacks.HostParameter, requirements abstract.HostSizingRequirements) (_ *abstract.HostFull, ferr fail.Error)
func (ProviderProxy) StartHost ¶
func (s ProviderProxy) StartHost(parameter stacks.HostParameter) (ferr fail.Error)
func (ProviderProxy) StopHost ¶
func (s ProviderProxy) StopHost(host stacks.HostParameter, gracefully bool) (ferr fail.Error)
func (ProviderProxy) UnbindHostFromVIP ¶
func (ProviderProxy) UnbindSecurityGroupFromHost ¶
func (s ProviderProxy) UnbindSecurityGroupFromHost(sgParam stacks.SecurityGroupParameter, hostParam stacks.HostParameter) (ferr fail.Error)
func (ProviderProxy) UnbindSecurityGroupFromSubnet ¶
func (s ProviderProxy) UnbindSecurityGroupFromSubnet(sgParam stacks.SecurityGroupParameter, subnetID string) (ferr fail.Error)
func (ProviderProxy) WaitHostReady ¶
func (s ProviderProxy) WaitHostReady(hostParam stacks.HostParameter, timeout time.Duration) (_ *abstract.HostCore, ferr fail.Error)