Skip to content

Commit

Permalink
fix(logging): make logs actually work
Browse files Browse the repository at this point in the history
  • Loading branch information
georgettica committed Oct 14, 2020
1 parent d351889 commit 96d4b0c
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,11 +64,13 @@ func main() {
"Enable leader election for controller manager. "+
"Enabling this will ensure there is only one active controller manager.")

opts := zap.Options{}
opts := zap.Options{
Development: true,
}
opts.BindFlags(flag.CommandLine)
flag.Parse()

ctrl.SetLogger(zap.New(zap.UseDevMode(true)))
ctrl.SetLogger(zap.New(zap.UseFlagOptions(&opts)))

mgr, err := ctrl.NewManager(ctrl.GetConfigOrDie(), ctrl.Options{
Scheme: scheme,
Expand Down

0 comments on commit 96d4b0c

Please sign in to comment.