Documentation
¶
Index ¶
- Constants
- func CleanJob(client crclient.Client, name string, namespace string) error
- func DeletePod(client crclient.Client, namespace, name string) error
- func GetOperatorNamespace() (string, error)
- func GetPodsBySelector(client crclient.Client, namespace string, selector string) (*corev1.PodList, error)
- func GetWatchNamespace() (string, error)
- func IsOpenShift() (bool, error)
- func IsWebhookConfigurationEnabled() (bool, error)
- func SyncJobToCluster(client crclient.Client, ctx context.Context, specJob *batchv1.Job) error
- func WaitForJobCompletion(client crclient.Client, name string, namespace string, timeout time.Duration) error
Constants ¶
View Source
const (
WatchNamespaceEnvVar = "WATCH_NAMESPACE"
)
Variables ¶
This section is empty.
Functions ¶
func CleanJob ¶
CleanJob cleans up a job in a given namespace. If a job didn't exist then it will throw isNotFound error
func GetOperatorNamespace ¶
GetOperatorNamespace returns the namespace the operator should be running in.
This function was ported over from Operator SDK 0.17.0 and modified.
func GetPodsBySelector ¶
func GetPodsBySelector(client crclient.Client, namespace string, selector string) (*corev1.PodList, error)
GetPodsBySelector selects all pods by a selector in a namespace
func GetWatchNamespace ¶
GetWatchNamespace returns the namespace the operator should be watching for changes
This function was ported over from Operator SDK 0.17.0
func IsOpenShift ¶
func IsWebhookConfigurationEnabled ¶
IsWebhookConfigurationEnabled returns true if both of mutating and validating webhook configurations are enabled
func SyncJobToCluster ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.