Skip to content

Commit

Permalink
feat(appset): make K8s client configurable (#18623)
Browse files Browse the repository at this point in the history
Signed-off-by: Alexy Mantha <alexy@mantha.dev>
  • Loading branch information
alexymantha committed Jun 26, 2024
1 parent ad5f672 commit 6f84afc
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,14 @@ func NewCommand() *cobra.Command {
}
}

mgr, err := ctrl.NewManager(ctrl.GetConfigOrDie(), ctrl.Options{
cfg := ctrl.GetConfigOrDie()
err = appv1alpha1.SetK8SConfigDefaults(cfg)
if err != nil {
log.Error(err, "Unable to apply K8s REST config defaults")
os.Exit(1)
}

mgr, err := ctrl.NewManager(cfg, ctrl.Options{
Scheme: scheme,
Metrics: metricsserver.Options{
BindAddress: metricsAddr,
Expand Down

0 comments on commit 6f84afc

Please # to comment.