workload

package
v0.1.29 Latest Latest
Warning

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

Go to latest
Published: Aug 26, 2026 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var LogKinds = []string{"Pod", "Deployment", "StatefulSet", "DaemonSet"}

Functions

func ResolvePods

func ResolvePods(
	ctx context.Context,
	client kubernetes.Interface,
	resources []Resource,
) ([]corev1.Pod, error)

Types

type ListOptions

type ListOptions struct {
	Selector Selector
	Limit    int
}

type ListResult

type ListResult struct {
	Resources []Resource
	Total     int
	Truncated bool
}

func List

func List(ctx context.Context, client kubernetes.Interface, options ListOptions) (ListResult, error)

type Resource

type Resource struct {
	Kind      string            `json:"kind"`
	Namespace string            `json:"namespace"`
	Name      string            `json:"name"`
	UID       string            `json:"uid"`
	Labels    map[string]string `json:"labels,omitempty"`
	// contains filtered or unexported fields
}

type Selector

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

func ParseSelector

func ParseSelector(raw string) (Selector, error)

func (Selector) And

func (s Selector) And(other Selector) Selector

func (Selector) Exact

func (s Selector) Exact() bool

func (Selector) Filter

func (s Selector) Filter(resources []Resource) []Resource

func (Selector) Matches

func (s Selector) Matches(resource Resource) bool

Jump to

Keyboard shortcuts

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