k8s

package
v1.45.1 Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2025 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DeploymentHelper

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

func NewDeploymentHelper

func NewDeploymentHelper(client *kubernetes.Clientset, cfg *rest.Config, svc *appsv1.Deployment) *DeploymentHelper

func (*DeploymentHelper) WaitForCondition

func (s *DeploymentHelper) WaitForCondition(ctx context.Context, fn func(*appsv1.Deployment) (bool, error), timeout time.Duration) error

type PodHelper

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

func NewPodHelper

func NewPodHelper(client *kubernetes.Clientset, cfg *rest.Config, pod *corev1.Pod) *PodHelper

func (*PodHelper) Attach

func (p *PodHelper) Attach(ctx context.Context, container string, stdin io.Reader) (string, string, error)

func (*PodHelper) Create

func (p *PodHelper) Create(ctx context.Context) error

func (*PodHelper) Delete

func (p *PodHelper) Delete(ctx context.Context) error

func (*PodHelper) Exec

func (p *PodHelper) Exec(ctx context.Context, container string, cmd []string) (string, string, error)

func (*PodHelper) GetLogs

func (p *PodHelper) GetLogs(ctx context.Context, container string) (string, error)

func (*PodHelper) WaitForContainerReady

func (p *PodHelper) WaitForContainerReady(ctx context.Context, timeout time.Duration, container string) error

func (*PodHelper) WaitForContainerStarted

func (p *PodHelper) WaitForContainerStarted(ctx context.Context, timeout time.Duration, container string) error

func (*PodHelper) WaitForInitContainerRunning

func (p *PodHelper) WaitForInitContainerRunning(ctx context.Context, container string, timeout time.Duration) error

func (*PodHelper) WaitForPodDeleted

func (p *PodHelper) WaitForPodDeleted(ctx context.Context, timeout time.Duration) error

func (*PodHelper) WaitForPodPhase

func (p *PodHelper) WaitForPodPhase(ctx context.Context, timeout time.Duration, phase corev1.PodPhase) error

func (*PodHelper) WaitForPodRunning

func (p *PodHelper) WaitForPodRunning(ctx context.Context, timeout time.Duration) error

func (*PodHelper) WaitForPodSucceeded

func (p *PodHelper) WaitForPodSucceeded(ctx context.Context, timeout time.Duration) error

type PvcHelper

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

func NewPvcHelper

func NewPvcHelper(client *kubernetes.Clientset, cfg *rest.Config, pvc *corev1.PersistentVolumeClaim) *PvcHelper

func (*PvcHelper) DownloadGenesis

func (h *PvcHelper) DownloadGenesis(ctx context.Context, url, path, pc string, af *corev1.Affinity, ns map[string]string) error

func (*PvcHelper) WriteToFile

func (h *PvcHelper) WriteToFile(ctx context.Context, content, path, pc string, af *corev1.Affinity, ns map[string]string) error

type ServiceHelper

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

func NewServiceHelper

func NewServiceHelper(client *kubernetes.Clientset, cfg *rest.Config, svc *corev1.Service) *ServiceHelper

func (*ServiceHelper) WaitForCondition

func (s *ServiceHelper) WaitForCondition(ctx context.Context, fn func(service *corev1.Service) (bool, error), timeout time.Duration) error

Jump to

Keyboard shortcuts

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