Documentation
¶
Overview ¶
Package pods provides pod utilities to manage pods inside K8s
Index ¶
- func CreateAndWaitForReady(ctx context.Context, crudClient client.Client, pod *corev1.Pod, ...) error
- func Delete(ctx context.Context, crudClient client.Client, namespace, name string, ...) error
- func Get(ctx context.Context, crudClient client.Client, namespace, podName string) (*corev1.Pod, error)
- func HasAnnotations(pod corev1.Pod, annotations map[string]string) bool
- func HasCondition(pod *corev1.Pod, conditionType corev1.PodConditionType, ...) bool
- func HasLabels(pod corev1.Pod, labels map[string]string) bool
- func List(ctx context.Context, crudClient client.Client, namespace string) (*corev1.PodList, error)
- func Logs(ctx context.Context, kubeInterface kubernetes.Interface, ...) (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateAndWaitForReady ¶
func CreateAndWaitForReady( ctx context.Context, crudClient client.Client, pod *corev1.Pod, timeoutSeconds uint, ) error
CreateAndWaitForReady creates a given pod object and wait for it to be ready
func Delete ¶
func Delete( ctx context.Context, crudClient client.Client, namespace, name string, opts ...client.DeleteOption, ) error
Delete deletes a pod if existent
func Get ¶
func Get( ctx context.Context, crudClient client.Client, namespace, podName string, ) (*corev1.Pod, error)
Get gets a pod by namespace and name
func HasAnnotations ¶
HasAnnotations verifies that the annotations of a pod contain a specified annotations map
func HasCondition ¶
func HasCondition(pod *corev1.Pod, conditionType corev1.PodConditionType, status corev1.ConditionStatus) bool
HasCondition verifies that a pod has a specified condition
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.