kubernetes

package
v0.8.0-rc.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 6, 2020 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ComponentsIndexInformer

func ComponentsIndexInformer(
	client scheme.Interface,
	namespace string,
	fieldSelector fields.Selector,
	labelSelector labels.Selector,
) cache.SharedIndexInformer

func DeploymentsIndexInformer

func DeploymentsIndexInformer(
	client kubernetes.Interface,
	namespace string,
	fieldSelector fields.Selector,
	labelSelector labels.Selector,
) cache.SharedIndexInformer

Types

type API added in v0.2.0

type API struct {
	// contains filtered or unexported fields
}

func NewAPI added in v0.2.0

func NewAPI(kubeClient kubernetes.Interface, daprClient scheme.Interface) *API

NewAPI returns api to interact with kubernetes

func (*API) CreateService added in v0.2.0

func (a *API) CreateService(service *corev1.Service, namespace string) error

CreateService creates a new service

func (*API) DeleteService added in v0.2.0

func (a *API) DeleteService(serviceName string, namespace string) error

Delete a service

func (*API) GetDaprClient added in v0.2.0

func (a *API) GetDaprClient() scheme.Interface

GetDaprClient returns Dapr Client

func (*API) GetDeployment added in v0.2.0

func (a *API) GetDeployment(name, namespace string) (*appsv1.Deployment, error)

GetDeployment gets a deployment

func (*API) GetDeploymentsBySelector added in v0.2.0

func (a *API) GetDeploymentsBySelector(selector meta_v1.LabelSelector) ([]appsv1.Deployment, error)

GetDeploymentsBySelector returns a deployment by a selector

func (*API) GetEndpoints added in v0.2.0

func (a *API) GetEndpoints(name, namespace string) (*corev1.Endpoints, error)

GetEndpoints returns a list of service endpoints

func (*API) GetKubeClient added in v0.2.0

func (a *API) GetKubeClient() kubernetes.Interface

GetKubeClient returns Kube Client

func (*API) ServiceExists added in v0.2.0

func (a *API) ServiceExists(name, namespace string) bool

ServiceExists checks if a service already exists

func (*API) UpdateDeployment added in v0.2.0

func (a *API) UpdateDeployment(deployment *appsv1.Deployment) error

UpdateDeployment updates an existing deployment

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL