k8s

package
v1.19.1-0...-4baae3d Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EnsureObjectDeleted

func EnsureObjectDeleted(ctx context.Context, client k8sclient.Client, object k8sclient.Object) (integreatlyv1alpha1.StatusPhase, error)

EnsureObjectDeleted attempts to delete a kubernetes object and if it's not found returns PhaseCompleted

func Exists

func Exists(ctx context.Context, serverClient k8sclient.Client, obj k8sclient.Object) (bool, error)

Exists checks if obj exists on the cluster accessible by serverClient

func GetWatchNamespace

func GetWatchNamespace() (string, error)

GetWatchNamespace returns the Namespace the operator should be watching for changes

func IsRunInCluster

func IsRunInCluster() bool

IsRunInCluster checks if the operator is run in cluster

func IsRunLocally

func IsRunLocally() bool

IsRunLocally checks if the operator is run locally

func PatchIfExists

PatchIfExists uses serverClient to retrieve obj by its object key. If obj is not found, it returns InProgress. If obj is found, it applies fn and merge patches the object

func UpdateIfExists

UpdateIfExists uses serverClient to retrieve obj by it's object key. If obj is not found, it returns InProgress. If obj is found, it applies fn and updates the object

Types

This section is empty.

Jump to

Keyboard shortcuts

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