Skip to content

Commit

Permalink
chore: rm log init in main and fix operator scope message
Browse files Browse the repository at this point in the history
  • Loading branch information
Baarsgaard committed Jan 11, 2025
1 parent ad98c59 commit 600d74a
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ func main() {
case strings.Contains(watchNamespace, ","):
// multi namespace scoped
controllerOptions.Cache.DefaultNamespaces = getNamespaceConfig(watchNamespace)
setupLog.Info("manager set up with multiple namespaces", "namespaces", watchNamespace)
setupLog.Info("operator running in namespace scoped mode for multiple namespaces", "namespaces", watchNamespace)
case watchNamespace != "":
// namespace scoped
controllerOptions.Cache.DefaultNamespaces = getNamespaceConfig(watchNamespace)
Expand Down Expand Up @@ -216,15 +216,13 @@ func main() {
if err = (&controllers.GrafanaDashboardReconciler{
Client: mgr.GetClient(),
Scheme: mgr.GetScheme(),
Log: ctrl.Log.WithName("DashboardReconciler"),
}).SetupWithManager(mgr, ctx); err != nil {
setupLog.Error(err, "unable to create controller", "controller", "GrafanaDashboard")
os.Exit(1)
}
if err = (&controllers.GrafanaDatasourceReconciler{
Client: mgr.GetClient(),
Scheme: mgr.GetScheme(),
Log: ctrl.Log.WithName("DatasourceReconciler"),
}).SetupWithManager(mgr, ctx); err != nil {
setupLog.Error(err, "unable to create controller", "controller", "GrafanaDatasource")
os.Exit(1)
Expand Down

0 comments on commit 600d74a

Please sign in to comment.