package
0.0.0-20250228164547-bad2d1bf3a37
Repository: https://github.com/openshift/library-go.git
Documentation: pkg.go.dev
# Functions
BehaviorOnPanic is a helper for setting the crash mode of OpenShift when a panic is caught.
InitLogrus initializes logrus by setting a loglevel for it.
InitLogrusFromKlog sets the logrus trace level based on the klog trace level.
Profile returns an interface to defer for a profile: `defer serviceability.Profile(os.Getenv("OPENSHIFT_PROFILE")).Stop()` is common.
StartProfiler starts the golang profiler on a port if `web` is specified.
# Interfaces
Stop is a function to defer in your main call to provide profile info.