k8s

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Dec 31, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	// GetContainerListener returns a listener that emits container deltas for a given cluster and namespace
	GetContainerListener(
		cluster,
		namespace string,
		matchers model.Matchers,
		selector labels.Selector,
		ignorePodOwnerTypes []string,
	) (model.ContainerListener, error)

	// CollectContainerDeltasForDuration collects container deltas from a listener for a given duration
	CollectContainerDeltasForDuration(listener model.ContainerListener, duration time.Duration) (model.ContainerDeltaSet, error)

	// GetContainerStatus returns the status of a container
	GetContainerStatus(container model.Container) (model.ContainerStatus, error)

	// GetLogStream returns a scanner that reads lines from a container's log stream
	GetLogStream(container model.Container, sinceTime time.Time) (*bufio.Scanner, context.CancelFunc, error)
}

Client is an interface for interacting with a Kubernetes cluster

func NewClient

func NewClient(ctx context.Context, clusterToClientset map[string]*kubernetes.Clientset) Client

Jump to

Keyboard shortcuts

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