Documentation
¶
Index ¶
- Variables
- func ProcessFilter(p CloudInfoProvider, r *components.CloudInfoRequest) (*components.GetCloudInfoResponse, error)
- type AmazonInfo
- func (a *AmazonInfo) GetImages(filter *components.ImageFilter) (map[string][]string, error)
- func (a *AmazonInfo) GetKubernetesVersion(*components.KubernetesFilter) (interface{}, error)
- func (a *AmazonInfo) GetLocations() ([]string, error)
- func (a *AmazonInfo) GetMachineTypes() (map[string]components.MachineType, error)
- func (a *AmazonInfo) GetMachineTypesWithFilter(filter *components.InstanceFilter) (map[string]components.MachineType, error)
- func (a *AmazonInfo) GetNameRegexp() string
- func (a *AmazonInfo) GetType() string
- type AzureInfo
- func (a *AzureInfo) GetImages(filter *components.ImageFilter) (map[string][]string, error)
- func (a *AzureInfo) GetKubernetesVersion(filter *components.KubernetesFilter) (interface{}, error)
- func (a *AzureInfo) GetLocations() ([]string, error)
- func (a *AzureInfo) GetMachineTypes() (map[string]components.MachineType, error)
- func (a *AzureInfo) GetMachineTypesWithFilter(filter *components.InstanceFilter) (map[string]components.MachineType, error)
- func (a *AzureInfo) GetNameRegexp() string
- func (a *AzureInfo) GetType() string
- type BaseFields
- type CloudInfoProvider
- type GoogleInfo
- func (g *GoogleInfo) GetImages(filter *components.ImageFilter) (map[string][]string, error)
- func (g *GoogleInfo) GetKubernetesVersion(filter *components.KubernetesFilter) (interface{}, error)
- func (g *GoogleInfo) GetLocations() ([]string, error)
- func (g *GoogleInfo) GetMachineTypes() (map[string]components.MachineType, error)
- func (g *GoogleInfo) GetMachineTypesWithFilter(filter *components.InstanceFilter) (map[string]components.MachineType, error)
- func (g *GoogleInfo) GetNameRegexp() string
- func (g *GoogleInfo) GetType() string
Constants ¶
This section is empty.
Variables ¶
var ( // Keywords are the supported filter words Keywords = []string{ constants.KeyWordLocation, constants.KeyWordInstanceType, constants.KeyWordKubernetesVersion, constants.KeyWordImage, } )
Functions ¶
func ProcessFilter ¶
func ProcessFilter(p CloudInfoProvider, r *components.CloudInfoRequest) (*components.GetCloudInfoResponse, error)
ProcessFilter returns the proper supported fields, the CloudInfoRequest decide which
Types ¶
type AmazonInfo ¶
type AmazonInfo struct {
BaseFields
}
AmazonInfo describes AWS with supported info
func (*AmazonInfo) GetImages ¶
func (a *AmazonInfo) GetImages(filter *components.ImageFilter) (map[string][]string, error)
GetImages returns supported AMIs
func (*AmazonInfo) GetKubernetesVersion ¶
func (a *AmazonInfo) GetKubernetesVersion(*components.KubernetesFilter) (interface{}, error)
GetKubernetesVersion returns supported k8s versions
func (*AmazonInfo) GetLocations ¶
func (a *AmazonInfo) GetLocations() ([]string, error)
GetLocations returns supported locations
func (*AmazonInfo) GetMachineTypes ¶
func (a *AmazonInfo) GetMachineTypes() (map[string]components.MachineType, error)
GetMachineTypes returns supported machine types
func (*AmazonInfo) GetMachineTypesWithFilter ¶
func (a *AmazonInfo) GetMachineTypesWithFilter(filter *components.InstanceFilter) (map[string]components.MachineType, error)
GetMachineTypesWithFilter returns supported machine types by location
func (*AmazonInfo) GetNameRegexp ¶
func (a *AmazonInfo) GetNameRegexp() string
GetNameRegexp returns regexp for cluster name
type AzureInfo ¶
type AzureInfo struct {
BaseFields
}
AzureInfo describes AKS with supported info
func (*AzureInfo) GetImages ¶
func (a *AzureInfo) GetImages(filter *components.ImageFilter) (map[string][]string, error)
GetImages returns with the supported images (in case of AKS is undefined)
func (*AzureInfo) GetKubernetesVersion ¶
func (a *AzureInfo) GetKubernetesVersion(filter *components.KubernetesFilter) (interface{}, error)
GetKubernetesVersion returns supported k8s versions
func (*AzureInfo) GetLocations ¶
GetLocations returns supported locations
func (*AzureInfo) GetMachineTypes ¶
func (a *AzureInfo) GetMachineTypes() (map[string]components.MachineType, error)
GetMachineTypes returns supported machine types
func (*AzureInfo) GetMachineTypesWithFilter ¶
func (a *AzureInfo) GetMachineTypesWithFilter(filter *components.InstanceFilter) (map[string]components.MachineType, error)
GetMachineTypesWithFilter returns supported machine types by location
func (*AzureInfo) GetNameRegexp ¶
GetNameRegexp returns regexp for cluster name
type BaseFields ¶
BaseFields for cloud info types
type CloudInfoProvider ¶
type CloudInfoProvider interface { GetType() string GetNameRegexp() string GetLocations() ([]string, error) GetMachineTypes() (map[string]components.MachineType, error) GetMachineTypesWithFilter(*components.InstanceFilter) (map[string]components.MachineType, error) GetKubernetesVersion(*components.KubernetesFilter) (interface{}, error) GetImages(*components.ImageFilter) (map[string][]string, error) }
CloudInfoProvider interface for cloud supports
func GetCloudInfoModel ¶
func GetCloudInfoModel(cloudType string, r *components.CloudInfoRequest) (CloudInfoProvider, error)
GetCloudInfoModel creates CloudInfoProvider
type GoogleInfo ¶
type GoogleInfo struct {
BaseFields
}
GoogleInfo describes GKE with supported info
func (*GoogleInfo) GetImages ¶
func (g *GoogleInfo) GetImages(filter *components.ImageFilter) (map[string][]string, error)
GetImages returns with the supported images (in case of GKE is undefined)
func (*GoogleInfo) GetKubernetesVersion ¶
func (g *GoogleInfo) GetKubernetesVersion(filter *components.KubernetesFilter) (interface{}, error)
GetKubernetesVersion returns supported k8s versions
func (*GoogleInfo) GetLocations ¶
func (g *GoogleInfo) GetLocations() ([]string, error)
GetLocations returns supported locations
func (*GoogleInfo) GetMachineTypes ¶
func (g *GoogleInfo) GetMachineTypes() (map[string]components.MachineType, error)
GetMachineTypes returns supported machine types
func (*GoogleInfo) GetMachineTypesWithFilter ¶
func (g *GoogleInfo) GetMachineTypesWithFilter(filter *components.InstanceFilter) (map[string]components.MachineType, error)
GetMachineTypesWithFilter returns supported machine types by location
func (*GoogleInfo) GetNameRegexp ¶
func (g *GoogleInfo) GetNameRegexp() string
GetNameRegexp returns regexp for cluster name