diff --git a/infra/feast-operator/internal/controller/services/client.go b/infra/feast-operator/internal/controller/services/client.go index 89e22f7be6d..fbd972368fb 100644 --- a/infra/feast-operator/internal/controller/services/client.go +++ b/infra/feast-operator/internal/controller/services/client.go @@ -70,12 +70,11 @@ func (feast *FeastServices) createCaConfigMap() error { } func (feast *FeastServices) setCaConfigMap(cm *corev1.ConfigMap) error { - cm.Labels = map[string]string{ - NameLabelKey: feast.Handler.FeatureStore.Name, - } - cm.Annotations = map[string]string{ - "service.beta.openshift.io/inject-cabundle": "true", + cm.Labels = feast.getLabels() + if len(cm.Annotations) == 0 { + cm.Annotations = map[string]string{} } + cm.Annotations["service.beta.openshift.io/inject-cabundle"] = "true" return controllerutil.SetControllerReference(feast.Handler.FeatureStore, cm, feast.Handler.Scheme) } diff --git a/infra/feast-operator/internal/controller/services/services.go b/infra/feast-operator/internal/controller/services/services.go index 5cc9cc11267..768b4df74b1 100644 --- a/infra/feast-operator/internal/controller/services/services.go +++ b/infra/feast-operator/internal/controller/services/services.go @@ -586,9 +586,10 @@ func (feast *FeastServices) setInitContainer(podSpec *corev1.PodSpec, fsYamlB64 func (feast *FeastServices) setService(svc *corev1.Service, feastType FeastServiceType) error { svc.Labels = feast.getFeastTypeLabels(feastType) if feast.isOpenShiftTls(feastType) { - svc.Annotations = map[string]string{ - "service.beta.openshift.io/serving-cert-secret-name": svc.Name + tlsNameSuffix, + if len(svc.Annotations) == 0 { + svc.Annotations = map[string]string{} } + svc.Annotations["service.beta.openshift.io/serving-cert-secret-name"] = svc.Name + tlsNameSuffix } var port int32 = HttpPort