Skip to content

Commit

Permalink
normalize kafka user name
Browse files Browse the repository at this point in the history
  • Loading branch information
nasark committed Jan 21, 2024
1 parent da480ea commit 8d6201c
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ func MessagingEnvSecret(cr *miqv1alpha1.ManageIQ, client client.Client, scheme *
if err := controllerutil.SetControllerReference(cr, secret, scheme); err != nil {
return err
}
secretKey := types.NamespacedName{Namespace: cr.ObjectMeta.Namespace, Name: cr.Spec.AppName + "-user"}
secretKey := types.NamespacedName{Namespace: cr.ObjectMeta.Namespace, Name: cr.Spec.AppName + "-kafka-admin"}
kafkaUser := &corev1.Secret{}
secretErr := client.Get(context.TODO(), secretKey, kafkaUser)
if secretErr != nil {
Expand Down Expand Up @@ -487,7 +487,7 @@ func KafkaUser(cr *miqv1alpha1.ManageIQ, scheme *runtime.Scheme) (*unstructured.
Kind: "KafkaUser",
Version: "v1beta2",
})
kafkaUserCR.SetName(cr.Spec.AppName + "-user")
kafkaUserCR.SetName(cr.Spec.AppName + "-kafka-admin")
kafkaUserCR.SetNamespace(cr.Namespace)
kafkaUserCR.SetLabels(map[string]string{"strimzi.io/cluster": cr.Spec.AppName})

Expand Down

0 comments on commit 8d6201c

Please sign in to comment.