Documentation ¶
Index ¶
- Constants
- type AWSKopsConfig
- type Kops
- func (k Kops) CreateKubeCluster(newCluster federationv1beta1.Cluster) (*util.ClusterAnnotation, error)
- func (k Kops) DeleteKubeCluster(existingCluster federationv1beta1.Cluster) error
- func (k Kops) ExportKubeConfig(fedCluster federationv1beta1.Cluster) (*clientcmdapi.Config, error)
- func (k Kops) ExportKubeConfigBuilder(newClusterName string) (*kubeconfig.KubeconfigBuilder, error)
- func (k Kops) GetProviderName() string
- func (k Kops) ScaleKubeCluster(existingCluster federationv1beta1.Cluster, scaleSize int) (*util.ClusterAnnotation, error)
- func (k Kops) ValidateKubeCluster(fedCluster federationv1beta1.Cluster) (*util.ClusterAnnotation, error)
Constants ¶
View Source
const ( ProviderName = "aws-kops" DefaultMasterSize = "t2.medium" DefaultNodeSize = "t2.small" DefaultNumberOfMasters = "1" DefaultNumberOfNodes = "1" InstanceGroupMaster = "master" InstanceGroupNodes = "nodes" AWSAccessKeyId = "AWS_ACCESS_KEY_ID" AWSSecretAccessKeyId = "AWS_SECRET_ACCESS_KEY" CalicoNetwork = "calico" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AWSKopsConfig ¶
type AWSKopsConfig struct { Provider string `json:"provider,omitempty"` Region string `json:"region,omitempty"` MasterZones []string `json:"masterZones,omitempty"` NodeZones []string `json:"nodeZones,omitempty"` MasterSize string `json:"masterSize,omitempty"` NodeSize string `json:"nodeSize,omitempty"` NumberOfMasters string `json:"numberOfMasters,omitempty"` NumberOfNodes string `json:"numberOfNodes,omitempty"` MaxNumberOfNodes string `json:"maxNumberOfNodes,omitempty"` MinNumberOfNodes string `json:"minNumberOfNodes,omitempty"` NetworkProvider string `json:"networkProvider,omitempty"` NodeNetwork string `json:"nodeNetwork,omitempty"` PodNetwork string `json:"podNetwork,omitempty"` SshKey string `json:"sshkey,omitempty"` MaxPods string `json:"maxPods,omitempty"` }
Sample Data: '{ "provider": "aws", "region": "us-east-2", "masterZones": ["us-east-2a"], "nodeZones": ["us-east-2a"], "masterSize": "t2.small", "nodeSize": "t2.micro", "numberOfMasters": "1", "numberOfNodes": "1" }'
type Kops ¶
type Kops struct {
// contains filtered or unexported fields
}
func NewAwsKops ¶
func NewAwsKops(config *options.ClusterControllerOptions) (*Kops, error)
func (Kops) CreateKubeCluster ¶
func (k Kops) CreateKubeCluster(newCluster federationv1beta1.Cluster) (*util.ClusterAnnotation, error)
returns nil as providerId and error
func (Kops) DeleteKubeCluster ¶
func (k Kops) DeleteKubeCluster(existingCluster federationv1beta1.Cluster) error
func (Kops) ExportKubeConfig ¶
func (k Kops) ExportKubeConfig(fedCluster federationv1beta1.Cluster) (*clientcmdapi.Config, error)
func (Kops) ExportKubeConfigBuilder ¶
func (k Kops) ExportKubeConfigBuilder(newClusterName string) (*kubeconfig.KubeconfigBuilder, error)
func (Kops) GetProviderName ¶
func (Kops) ScaleKubeCluster ¶
func (k Kops) ScaleKubeCluster(existingCluster federationv1beta1.Cluster, scaleSize int) (*util.ClusterAnnotation, error)
*
- Scale Cluster Nodes. A positive scaleSize means it is a scale up and a negative value means it is a scale down.
- The function returns the target node count and error value.
func (Kops) ValidateKubeCluster ¶
func (k Kops) ValidateKubeCluster(fedCluster federationv1beta1.Cluster) (*util.ClusterAnnotation, error)
Click to show internal directories.
Click to hide internal directories.