File tree 1 file changed +5
-1
lines changed
pkg/k8sutils/templates/service
1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change 15
15
package service
16
16
17
17
import (
18
- "github.com/StarRocks/starrocks-kubernetes-operator/pkg/apis/starrocks/v1"
19
18
corev1 "k8s.io/api/core/v1"
19
+
20
+ "github.com/StarRocks/starrocks-kubernetes-operator/pkg/apis/starrocks/v1"
20
21
)
21
22
22
23
func MakeSearchService (serviceName string , externalService * corev1.Service , ports []corev1.ServicePort ) * corev1.Service {
23
24
searchSvc := & corev1.Service {}
24
25
externalService .ObjectMeta .DeepCopyInto (& searchSvc .ObjectMeta )
26
+ // some service annotations can only be used when `type` is 'LoadBalancer', e.g. service.beta.kubernetes.io/load-balancer-source-ranges
27
+ // we do not need to annotations for search service
28
+ searchSvc .Annotations = nil
25
29
searchSvc .Name = serviceName
26
30
searchSvc .Spec = corev1.ServiceSpec {
27
31
ClusterIP : "None" ,
You can’t perform that action at this time.
0 commit comments