Skip to content

Commit

Permalink
Adapt code to updated dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
vpnachev committed Oct 25, 2024
1 parent b88d0bd commit 0bbfb06
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
8 changes: 5 additions & 3 deletions pkg/controller/seed/add.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import (
corev1 "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/client-go/kubernetes"
"sigs.k8s.io/controller-runtime/pkg/client"
"sigs.k8s.io/controller-runtime/pkg/controller"
"sigs.k8s.io/controller-runtime/pkg/handler"
"sigs.k8s.io/controller-runtime/pkg/manager"
Expand Down Expand Up @@ -80,9 +81,10 @@ func AddToManager(_ context.Context, mgr manager.Manager) error {
return err
}

return ctrl.Watch(
source.Kind(mgr.GetCache(), &corev1.Namespace{}),
return ctrl.Watch(source.Kind[client.Object](
mgr.GetCache(),
&corev1.Namespace{},
&handler.EnqueueRequestForObject{},
kubeSystemNamespacePredicate,
)
))
}
2 changes: 1 addition & 1 deletion pkg/lakom/resolvetag/admission.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ func (hb HandleBuilder) Build() (*handler, error) {

type handler struct {
reader client.Reader
decoder *admission.Decoder
decoder admission.Decoder
logger logr.Logger

resolver Resolver
Expand Down
2 changes: 1 addition & 1 deletion pkg/lakom/verifysignature/admission.go
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ func (hb HandleBuilder) Build() (*handler, error) {

type handler struct {
reader client.Reader
decoder *admission.Decoder
decoder admission.Decoder
logger logr.Logger

verifier Verifier
Expand Down

0 comments on commit 0bbfb06

Please sign in to comment.