Documentation
¶
Overview ¶
Util functions used by generated code.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ContainsString ¶
func ContainsString(slice []string, s string) bool
Helper functions to check a string from a slice of strings.
func ContextWithLogger ¶
func ContextWithLogger(ctx context.Context, logger logr.Logger) context.Context
store the logger in the context for propagation to children
func GetInClusterNamesapce ¶
func GetInClusterNamesapce() (string, error)
returns the namespace in which the current process is executing, if running inside k8s else, return err
func LoggerFromContext ¶
func LoggerFromContext(ctx context.Context) logr.Logger
retrieve the logger from the context returns the default logger if not set
func RemoveString ¶
func RemoveString(slice []string, s string) (result []string)
Helper functions to remove string from a slice of strings.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.