Skip to content

Commit

Permalink
Add missing control enabled check. (#42)
Browse files Browse the repository at this point in the history
  • Loading branch information
Daniel Swärd authored Jul 30, 2024
1 parent dfdeeed commit 74dea51
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions internal/server/command.go
Original file line number Diff line number Diff line change
Expand Up @@ -208,10 +208,12 @@ func (c *Command) Run(p cli.Params) error {
).Then(dsp.GetDSPRoutes(provider, store, reconciler, selfURL)),
))

ctlSVC := control.New(httpClient, store, reconciler, provider, selfURL)
err = c.startControl(ctx, wg, ctlSVC)
if err != nil {
return err
if c.ControlEnabled {
ctlSVC := control.New(httpClient, store, reconciler, provider, selfURL)
err = c.startControl(ctx, wg, ctlSVC)
if err != nil {
return err
}
}

srv := &http.Server{
Expand Down

0 comments on commit 74dea51

Please sign in to comment.