We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents f6e28c0 + 85a959a commit 459839dCopy full SHA for 459839d
main.go
@@ -43,6 +43,7 @@ import (
43
_ "k8s.io/client-go/plugin/pkg/client/auth/gcp"
44
ctrl "sigs.k8s.io/controller-runtime"
45
"sigs.k8s.io/controller-runtime/pkg/cache"
46
+ "sigs.k8s.io/controller-runtime/pkg/log"
47
"sigs.k8s.io/controller-runtime/pkg/log/zap"
48
"sigs.k8s.io/controller-runtime/pkg/metrics/server"
49
// +kubebuilder:scaffold:imports
@@ -159,6 +160,7 @@ func realMain() int {
159
160
EncodeCaller: zapcore.ShortCallerEncoder,
161
}
162
logger := zap.New(zap.Encoder(zapcore.NewJSONEncoder(logCfg)), zap.StacktraceLevel(uzap.PanicLevel))
163
+ log.SetLogger(logger)
164
165
mgr, err := ctrl.NewManager(ctrl.GetConfigOrDie(), ctrl.Options{
166
Scheme: scheme,
0 commit comments