Skip to content

Commit 5a00df6

Browse files
committed
fix allWatchFields for the different controllers
Signed-off-by: Martin Schuppert <[email protected]>
1 parent 53524c5 commit 5a00df6

File tree

6 files changed

+27
-9
lines changed

6 files changed

+27
-9
lines changed

controllers/designate_controller.go

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -234,15 +234,6 @@ const (
234234
tlsAPIPublicField = ".spec.tls.api.public.secretName"
235235
)
236236

237-
var (
238-
allWatchFields = []string{
239-
passwordSecretField,
240-
caBundleSecretNameField,
241-
tlsAPIInternalField,
242-
tlsAPIPublicField,
243-
}
244-
)
245-
246237
// SetupWithManager sets up the controller with the Manager.
247238
func (r *DesignateReconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager) error {
248239
// transportURLSecretFn - Watch for changes made to the secret associated with the RabbitMQ

controllers/designateapi_controller.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -359,6 +359,13 @@ func (r *DesignateAPIReconciler) findObjectsForSrc(ctx context.Context, src clie
359359

360360
l := log.FromContext(ctx).WithName("Controllers").WithName("DesignateAPI")
361361

362+
allWatchFields := []string{
363+
passwordSecretField,
364+
caBundleSecretNameField,
365+
tlsAPIInternalField,
366+
tlsAPIPublicField,
367+
}
368+
362369
for _, field := range allWatchFields {
363370
crList := &designatev1beta1.DesignateAPIList{}
364371
listOps := &client.ListOptions{

controllers/designatecentral_controller.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -314,6 +314,11 @@ func (r *DesignateCentralReconciler) findObjectsForSrc(ctx context.Context, src
314314

315315
l := log.FromContext(ctx).WithName("Controllers").WithName("DesignateCentral")
316316

317+
allWatchFields := []string{
318+
passwordSecretField,
319+
caBundleSecretNameField,
320+
}
321+
317322
for _, field := range allWatchFields {
318323
crList := &designatev1beta1.DesignateCentralList{}
319324
listOps := &client.ListOptions{

controllers/designatemdns_controller.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -313,6 +313,11 @@ func (r *DesignateMdnsReconciler) findObjectsForSrc(ctx context.Context, src cli
313313

314314
l := log.FromContext(ctx).WithName("Controllers").WithName("DesignateMdns")
315315

316+
allWatchFields := []string{
317+
passwordSecretField,
318+
caBundleSecretNameField,
319+
}
320+
316321
for _, field := range allWatchFields {
317322
crList := &designatev1beta1.DesignateMdnsList{}
318323
listOps := &client.ListOptions{

controllers/designateproducer_controller.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -313,6 +313,11 @@ func (r *DesignateProducerReconciler) findObjectsForSrc(ctx context.Context, src
313313

314314
l := log.FromContext(ctx).WithName("Controllers").WithName("DesignateProducer")
315315

316+
allWatchFields := []string{
317+
passwordSecretField,
318+
caBundleSecretNameField,
319+
}
320+
316321
for _, field := range allWatchFields {
317322
crList := &designatev1beta1.DesignateProducerList{}
318323
listOps := &client.ListOptions{

controllers/designateworker_controller.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -313,6 +313,11 @@ func (r *DesignateWorkerReconciler) findObjectsForSrc(ctx context.Context, src c
313313

314314
l := log.FromContext(ctx).WithName("Controllers").WithName("DesignateWorker")
315315

316+
allWatchFields := []string{
317+
passwordSecretField,
318+
caBundleSecretNameField,
319+
}
320+
316321
for _, field := range allWatchFields {
317322
crList := &designatev1beta1.DesignateWorkerList{}
318323
listOps := &client.ListOptions{

0 commit comments

Comments
 (0)