pods

package
v0.0.41101 Latest Latest
Warning

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

Go to latest
Published: Jul 20, 2022 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultDeletionTimeout = 120

DefaultDeletionTimeout contains the default pod deletion timeout in seconds

Variables

This section is empty.

Functions

func ExecCommandOnPod

func ExecCommandOnPod(c *kubernetes.Clientset, pod *corev1.Pod, command []string) ([]byte, error)

ExecCommandOnPod runs command in the pod and returns buffer output

func GetContainerIDByName

func GetContainerIDByName(pod *corev1.Pod, containerName string) (string, error)

GetContainerIDByName returns container ID under the pod by the container name

func GetLogs

func GetLogs(c *kubernetes.Clientset, pod *corev1.Pod) (string, error)

GetLogs returns logs of the specified pod

func GetPerformanceOperatorPod

func GetPerformanceOperatorPod() (*corev1.Pod, error)

GetPerformanceOperatorPod returns the pod running the Performance Profile Operator

func GetTestPod

func GetTestPod() *corev1.Pod

GetTestPod returns pod with the busybox image

func WaitForCondition

func WaitForCondition(pod *corev1.Pod, conditionType corev1.PodConditionType, conditionStatus corev1.ConditionStatus, timeout time.Duration) error

WaitForCondition waits until the pod will have specified condition type with the expected status

func WaitForDeletion

func WaitForDeletion(pod *corev1.Pod, timeout time.Duration) error

WaitForDeletion waits until the pod will be removed from the cluster

func WaitForPhase

func WaitForPhase(pod *corev1.Pod, phase corev1.PodPhase, timeout time.Duration) error

WaitForPhase waits until the pod will have specified phase

func WaitForPodOutput

func WaitForPodOutput(c *kubernetes.Clientset, pod *corev1.Pod, command []string) ([]byte, error)

func WaitForPredicate

func WaitForPredicate(pod *corev1.Pod, timeout time.Duration, pred func(pod *corev1.Pod) (bool, error)) error

WaitForPredicate waits until the given predicate against the pod returns true or error.

Types

This section is empty.

Jump to

Keyboard shortcuts

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