@@ -127,7 +127,8 @@ func main() {
127127 },
128128 LeaderElection : & configv1alpha1.LeaderElectionConfiguration {},
129129 },
130- MCAD : & mcadconfig.MCADConfiguration {},
130+ MCADEnabled : pointer .Bool (false ),
131+ MCAD : & mcadconfig.MCADConfiguration {},
131132 InstaScale : & config.InstaScaleConfiguration {
132133 Enabled : pointer .Bool (false ),
133134 InstaScaleConfiguration : instascaleconfig.InstaScaleConfiguration {
@@ -167,12 +168,14 @@ func main() {
167168 })
168169 exitOnError (err , "unable to start manager" )
169170
170- mcadQueueController := mcad .NewJobController (mgr .GetConfig (), cfg .MCAD , & mcadconfig.MCADConfigurationExtended {})
171- if mcadQueueController == nil {
172- // FIXME: update NewJobController so it follows Go idiomatic error handling and return an error instead of a nil object
173- os .Exit (1 )
171+ if pointer .BoolDeref (cfg .MCADEnabled , false ) {
172+ mcadQueueController := mcad .NewJobController (mgr .GetConfig (), cfg .MCAD , & mcadconfig.MCADConfigurationExtended {})
173+ if mcadQueueController == nil {
174+ // FIXME: update NewJobController so it follows Go idiomatic error handling and return an error instead of a nil object
175+ os .Exit (1 )
176+ }
177+ mcadQueueController .Run (ctx .Done ())
174178 }
175- mcadQueueController .Run (ctx .Done ())
176179
177180 if pointer .BoolDeref (cfg .InstaScale .Enabled , false ) {
178181 instaScaleController := & instascale.AppWrapperReconciler {
0 commit comments