Documentation ¶
Index ¶
- type K8sutil
- func (k *K8sutil) CreateClientMasterDeployment(deploymentType, baseImage string, replicas *int32, javaOptions string, ...) error
- func (k *K8sutil) CreateClientService() error
- func (k *K8sutil) CreateDataNodeDeployment(replicas *int32, baseImage, storageClass string, dataDiskSize string, ...) error
- func (k *K8sutil) CreateDataService() error
- func (k *K8sutil) CreateDiscoveryService() error
- func (k *K8sutil) CreateKubernetesThirdPartyResource() error
- func (k *K8sutil) CreateStorageClass(zone, storageClassProvisioner, storageType string) error
- func (k *K8sutil) DeleteClientMasterDeployment(deploymentType string) error
- func (k *K8sutil) DeleteServices()
- func (k *K8sutil) DeleteStatefulSet() error
- func (k *K8sutil) DeleteStorageClasses() error
- func (k *K8sutil) GetElasticSearchClusters() ([]myspec.ElasticsearchCluster, error)
- func (k *K8sutil) MonitorElasticSearchEvents(stopchan chan struct{}) (<-chan *myspec.ElasticsearchCluster, <-chan error)
- type KubeInterface
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type K8sutil ¶
type K8sutil struct { Config *rest.Config TprClient *rest.RESTClient Kclient KubeInterface MasterHost string }
K8sutil defines the kube object
func (*K8sutil) CreateClientMasterDeployment ¶
func (k *K8sutil) CreateClientMasterDeployment(deploymentType, baseImage string, replicas *int32, javaOptions string, resources myspec.Resources) error
CreateClientMasterDeployment creates the client or master deployment
func (*K8sutil) CreateClientService ¶
CreateClientService creates the client service
func (*K8sutil) CreateDataNodeDeployment ¶
func (k *K8sutil) CreateDataNodeDeployment(replicas *int32, baseImage, storageClass string, dataDiskSize string, resources myspec.Resources) error
CreateDataNodeDeployment creates the data node deployment
func (*K8sutil) CreateDataService ¶
CreateDataService creates the data service
func (*K8sutil) CreateDiscoveryService ¶
CreateDiscoveryService creates the discovery service
func (*K8sutil) CreateKubernetesThirdPartyResource ¶
CreateKubernetesThirdPartyResource checks if ElasticSearch TPR exists. If not, create
func (*K8sutil) CreateStorageClass ¶
CreateStorageClass creates a storage class NOTE: Right now only creating AWS EBS volumes type gp2
func (*K8sutil) DeleteClientMasterDeployment ¶
DeleteClientMasterDeployment deletes the client or master deployment
func (*K8sutil) DeleteServices ¶
func (k *K8sutil) DeleteServices()
DeleteServices creates the discovery service
func (*K8sutil) DeleteStatefulSet ¶
DeleteStatefulSet deletes the data statefulset
func (*K8sutil) DeleteStorageClasses ¶
DeleteStorageClasses removes storage classes tied to the operator
func (*K8sutil) GetElasticSearchClusters ¶
func (k *K8sutil) GetElasticSearchClusters() ([]myspec.ElasticsearchCluster, error)
GetElasticSearchClusters returns a list of custom clusters defined
func (*K8sutil) MonitorElasticSearchEvents ¶
func (k *K8sutil) MonitorElasticSearchEvents(stopchan chan struct{}) (<-chan *myspec.ElasticsearchCluster, <-chan error)
MonitorElasticSearchEvents watches for new or removed clusters
type KubeInterface ¶
type KubeInterface interface { Services(namespace string) coreType.ServiceInterface ThirdPartyResources() extensionsType.ThirdPartyResourceInterface Deployments(namespace string) extensionsType.DeploymentInterface StatefulSets(namespace string) appsType.StatefulSetInterface StorageClasses() storageType.StorageClassInterface ReplicaSets(namespace string) extensionsType.ReplicaSetInterface }
KubeInterface abstracts the kubernetes client