File tree Expand file tree Collapse file tree 1 file changed +17
-1
lines changed
pkg/operator/certrotation Expand file tree Collapse file tree 1 file changed +17
-1
lines changed Original file line number Diff line number Diff line change 66 "time"
77
88 operatorv1 "github.com/openshift/api/operator/v1"
9+ corev1 "k8s.io/api/core/v1"
910 "k8s.io/apimachinery/pkg/util/wait"
1011
1112 "github.com/openshift/library-go/pkg/controller/factory"
@@ -82,7 +83,22 @@ func NewCertRotationController(
8283 return factory .New ().
8384 ResyncEvery (time .Minute ).
8485 WithSync (c .Sync ).
85- WithInformers (
86+ WithFilteredEventsInformers (
87+ func (obj interface {}) bool {
88+ if cm , ok := obj .(* corev1.ConfigMap ); ok {
89+ return cm .Namespace == caBundleConfigMap .Namespace && cm .Name == caBundleConfigMap .Name
90+ }
91+ if secret , ok := obj .(* corev1.Secret ); ok {
92+ if secret .Namespace == rotatedSigningCASecret .Namespace && secret .Name == rotatedSigningCASecret .Name {
93+ return true
94+ }
95+ if secret .Namespace == rotatedSelfSignedCertKeySecret .Namespace && secret .Name == rotatedSelfSignedCertKeySecret .Name {
96+ return true
97+ }
98+ return false
99+ }
100+ return true
101+ },
86102 rotatedSigningCASecret .Informer .Informer (),
87103 caBundleConfigMap .Informer .Informer (),
88104 rotatedSelfSignedCertKeySecret .Informer .Informer (),
You can’t perform that action at this time.
0 commit comments