Skip to content

Commit

Permalink
...
Browse files Browse the repository at this point in the history
  • Loading branch information
eberlep committed Sep 16, 2024
1 parent d5b98e8 commit e70a6dc
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -490,6 +490,21 @@ func main() {
}
// +kubebuilder:scaffold:builder

ctx := context.Background()

// update all existing operators to the current version
if err := opMgr.UpdateAllManagedOperators(ctx); err != nil {
setupLog.Error(err, "error updating the postgres operators")
}

setupLog.Info("starting service cluster manager", "version", v.V)
go func() {
if err := svcClusterMgr.Start(ctx); err != nil {
setupLog.Error(err, "problem running service cluster manager")
os.Exit(1)
}
}()

svcClusterMgr.GetWebhookServer().Register(
"/mutate-apps-v1-statefulset",
&webhook.Admission{
Expand All @@ -509,21 +524,6 @@ func main() {
// os.Exit(1)
// }

ctx := context.Background()

// update all existing operators to the current version
if err := opMgr.UpdateAllManagedOperators(ctx); err != nil {
setupLog.Error(err, "error updating the postgres operators")
}

setupLog.Info("starting service cluster manager", "version", v.V)
go func() {
if err := svcClusterMgr.Start(ctx); err != nil {
setupLog.Error(err, "problem running service cluster manager")
os.Exit(1)
}
}()

setupLog.Info("starting control plane cluster manager", "version", v.V)
if err := ctrlPlaneClusterMgr.Start(ctx); err != nil {
setupLog.Error(err, "problem running control plane cluster manager")
Expand Down

0 comments on commit e70a6dc

Please sign in to comment.