Skip to content

Commit

Permalink
use new NewStaticPodOperatorClient signature
Browse files Browse the repository at this point in the history
  • Loading branch information
sanchezl committed Oct 31, 2024
1 parent b114bc8 commit c5b19f0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/operator/starter.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ import (
"github.com/openshift/library-go/pkg/operator/status"
"github.com/openshift/library-go/pkg/operator/unsupportedconfigoverridescontroller"
"github.com/openshift/library-go/pkg/operator/v1helpers"
"k8s.io/utils/clock"

"k8s.io/apimachinery/pkg/api/errors"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
Expand Down Expand Up @@ -173,7 +174,7 @@ func RunOperator(ctx context.Context, controllerContext *controllercmd.Controlle
// we keep the default behavior of exiting the controller once a gate changes
featureGateAccessor.SetChangeHandler(featuregates.ForceExit)

operatorClient, dynamicInformers, err := genericoperatorclient.NewStaticPodOperatorClient(controllerContext.KubeConfig, operatorv1.GroupVersion.WithResource("etcds"), operatorv1.GroupVersion.WithKind("Etcd"), ExtractStaticPodOperatorSpec, ExtractStaticPodOperatorStatus)
operatorClient, dynamicInformers, err := genericoperatorclient.NewStaticPodOperatorClient(clock.RealClock{}, controllerContext.KubeConfig, operatorv1.GroupVersion.WithResource("etcds"), operatorv1.GroupVersion.WithKind("Etcd"), ExtractStaticPodOperatorSpec, ExtractStaticPodOperatorStatus)
if err != nil {
return err
}
Expand Down

0 comments on commit c5b19f0

Please sign in to comment.