kube

package
v0.0.0-...-d7ecc2e Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2024 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Adapter

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

func NewAdapter

func NewAdapter(kubeClient kube.Interface, chopClient chopClientSet.Interface, namer interfaces.INameManager) *Adapter

func (*Adapter) CR

func (k *Adapter) CR() interfaces.IKubeCR

CR is a getter

func (*Adapter) ConfigMap

func (k *Adapter) ConfigMap() interfaces.IKubeConfigMap

ConfigMap is a getter

func (*Adapter) Deployment

func (k *Adapter) Deployment() interfaces.IKubeDeployment

Deployment is a getter

func (*Adapter) Event

func (k *Adapter) Event() interfaces.IKubeEvent

Event is a getter

func (*Adapter) PDB

func (k *Adapter) PDB() interfaces.IKubePDB

PDB is a getter

func (*Adapter) Pod

func (k *Adapter) Pod() interfaces.IKubePod

Pod is a getter

func (*Adapter) ReplicaSet

func (k *Adapter) ReplicaSet() interfaces.IKubeReplicaSet

ReplicaSet is a getter

func (*Adapter) STS

func (k *Adapter) STS() interfaces.IKubeSTS

STS is a getter

func (*Adapter) Secret

func (k *Adapter) Secret() interfaces.IKubeSecret

Secret is a getter

func (*Adapter) Service

func (k *Adapter) Service() interfaces.IKubeService

Service is a getter

func (*Adapter) Storage

func (k *Adapter) Storage() interfaces.IKubeStoragePVC

Storage is a getter

type CR

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

func NewCR

func NewCR(chopClient chopClientSet.Interface) *CR

func (*CR) Get

func (c *CR) Get(ctx context.Context, namespace, name string) (api.ICustomResource, error)

func (*CR) StatusUpdate

func (c *CR) StatusUpdate(ctx context.Context, cr api.ICustomResource, opts commonTypes.UpdateStatusOptions) (err error)

updateCHIObjectStatus updates ClickHouseInstallation object's Status

type ConfigMap

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

func NewConfigMap

func NewConfigMap(kubeClient kube.Interface) *ConfigMap

func (*ConfigMap) Create

func (c *ConfigMap) Create(ctx context.Context, cm *core.ConfigMap) (*core.ConfigMap, error)

func (*ConfigMap) Delete

func (c *ConfigMap) Delete(ctx context.Context, namespace, name string) error

func (*ConfigMap) Get

func (c *ConfigMap) Get(ctx context.Context, namespace, name string) (*core.ConfigMap, error)

func (*ConfigMap) List

func (c *ConfigMap) List(ctx context.Context, namespace string, opts meta.ListOptions) ([]core.ConfigMap, error)

func (*ConfigMap) Update

func (c *ConfigMap) Update(ctx context.Context, cm *core.ConfigMap) (*core.ConfigMap, error)

type Deployment

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

func NewDeployment

func NewDeployment(kubeClient kube.Interface) *Deployment

func (*Deployment) Get

func (c *Deployment) Get(namespace, name string) (*apps.Deployment, error)

func (*Deployment) Update

func (c *Deployment) Update(deployment *apps.Deployment) (*apps.Deployment, error)

type Event

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

func NewEvent

func NewEvent(kubeClient kube.Interface) *Event

func (*Event) Create

func (c *Event) Create(ctx context.Context, event *core.Event) (*core.Event, error)

type PDB

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

func NewPDB

func NewPDB(kubeClient kube.Interface) *PDB

func (*PDB) Create

func (*PDB) Delete

func (c *PDB) Delete(ctx context.Context, namespace, name string) error

func (*PDB) Get

func (c *PDB) Get(ctx context.Context, namespace, name string) (*policy.PodDisruptionBudget, error)

func (*PDB) List

func (c *PDB) List(ctx context.Context, namespace string, opts meta.ListOptions) ([]policy.PodDisruptionBudget, error)

func (*PDB) Update

type PVC

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

func NewPVC

func NewPVC(kubeClient kube.Interface) *PVC

func (*PVC) Create

func (*PVC) Delete

func (c *PVC) Delete(ctx context.Context, namespace, name string) error

func (*PVC) Get

func (c *PVC) Get(ctx context.Context, namespace, name string) (*core.PersistentVolumeClaim, error)

func (*PVC) List

func (c *PVC) List(ctx context.Context, namespace string, opts meta.ListOptions) ([]core.PersistentVolumeClaim, error)

func (*PVC) ListForHost

func (c *PVC) ListForHost(ctx context.Context, host *api.Host) (*core.PersistentVolumeClaimList, error)

func (*PVC) Update

type Pod

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

func NewPod

func NewPod(kubeClient kube.Interface, namer interfaces.INameManager) *Pod

func (*Pod) Delete

func (c *Pod) Delete(ctx context.Context, namespace, name string) error

func (*Pod) Get

func (c *Pod) Get(params ...any) (*core.Pod, error)

getPod gets pod. Accepted types:

  1. *apps.StatefulSet
  2. *chop.Host

func (*Pod) GetAll

func (c *Pod) GetAll(obj any) []*core.Pod

GetAll gets all pods for provided entity

func (*Pod) Update

func (c *Pod) Update(ctx context.Context, pod *core.Pod) (*core.Pod, error)

type ReplicaSet

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

func NewReplicaSet

func NewReplicaSet(kubeClient kube.Interface) *ReplicaSet

func (*ReplicaSet) Get

func (c *ReplicaSet) Get(ctx context.Context, namespace, name string) (*apps.ReplicaSet, error)

func (*ReplicaSet) Update

func (c *ReplicaSet) Update(ctx context.Context, replicaSet *apps.ReplicaSet) (*apps.ReplicaSet, error)

type STS

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

func NewSTS

func NewSTS(kubeClient kube.Interface, namer interfaces.INameManager) *STS

func (*STS) Create

func (c *STS) Create(ctx context.Context, statefulSet *apps.StatefulSet) (*apps.StatefulSet, error)

func (*STS) Delete

func (c *STS) Delete(ctx context.Context, namespace, name string) error

Delete gracefully deletes StatefulSet through zeroing Pod's count

func (*STS) Get

func (c *STS) Get(ctx context.Context, params ...any) (*apps.StatefulSet, error)

Get gets StatefulSet. Accepted types:

  1. *meta.ObjectMeta
  2. *chop.Host

func (*STS) List

func (c *STS) List(ctx context.Context, namespace string, opts meta.ListOptions) ([]apps.StatefulSet, error)

func (*STS) Update

func (c *STS) Update(ctx context.Context, sts *apps.StatefulSet) (*apps.StatefulSet, error)

Update is an internal function, used in reconcileStatefulSet only

type Secret

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

func NewSecret

func NewSecret(kubeClient kube.Interface, namer interfaces.INameManager) *Secret

func (*Secret) Create

func (c *Secret) Create(ctx context.Context, svc *core.Secret) (*core.Secret, error)

func (*Secret) Delete

func (c *Secret) Delete(ctx context.Context, namespace, name string) error

func (*Secret) Get

func (c *Secret) Get(ctx context.Context, params ...any) (*core.Secret, error)

Get gets Secret. Accepted types:

  1. *core.Service
  2. *chop.Host

func (*Secret) List

func (c *Secret) List(ctx context.Context, namespace string, opts meta.ListOptions) ([]core.Secret, error)

func (*Secret) Update

func (c *Secret) Update(ctx context.Context, svc *core.Secret) (*core.Secret, error)

type Service

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

func NewService

func NewService(kubeClient kube.Interface, namer interfaces.INameManager) *Service

func (*Service) Create

func (c *Service) Create(ctx context.Context, svc *core.Service) (*core.Service, error)

func (*Service) Delete

func (c *Service) Delete(ctx context.Context, namespace, name string) error

func (*Service) Get

func (c *Service) Get(ctx context.Context, params ...any) (*core.Service, error)

Get gets Service. Accepted types:

  1. *core.Service
  2. *chop.Host

func (*Service) List

func (c *Service) List(ctx context.Context, namespace string, opts meta.ListOptions) ([]core.Service, error)

func (*Service) Update

func (c *Service) Update(ctx context.Context, svc *core.Service) (*core.Service, error)

Jump to

Keyboard shortcuts

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