File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ kind: Service
77metadata :
88 name : {{ include "temporal.componentname" (list $ $service) }}
99 labels :
10- {{- include "temporal.resourceLabels" (list $ $service "") | nindent 4 }}
10+ {{- include "temporal.resourceLabels" (list $ $service "service ") | nindent 4 }}
1111 {{- if $serviceValues.service.annotations }}
1212 annotations : {{- include "common.tplvalues.render" ( dict "value" $serviceValues.service.annotations "context" $) | nindent 4 }}
1313 {{- end }}
Original file line number Diff line number Diff line change @@ -530,3 +530,22 @@ tests:
530530 port : 9090
531531 protocol : TCP
532532 targetPort : metrics
533+ - it : add custom label for frontend service
534+ template : templates/server-service.yaml
535+ documentSelector :
536+ path : ' $[?(@.metadata.name == "RELEASE-NAME-temporal-frontend")].kind'
537+ value : Service
538+ matchMany : true
539+ set :
540+ server :
541+ frontend :
542+ serviceLabels :
543+ label1 : value1
544+ label2 : value2
545+ asserts :
546+ - equal :
547+ path : metadata.labels["label1"]
548+ value : value1
549+ - equal :
550+ path : metadata.labels["label2"]
551+ value : value2
Original file line number Diff line number Diff line change @@ -269,6 +269,7 @@ server:
269269 deploymentStrategy : {}
270270 podAnnotations : {}
271271 podLabels : {}
272+ serviceLabels : {}
272273 resources : {}
273274 nodeSelector : {}
274275 tolerations : []
@@ -306,6 +307,7 @@ server:
306307 deploymentStrategy : {}
307308 podAnnotations : {}
308309 podLabels : {}
310+ serviceLabels : {}
309311 resources : {}
310312 nodeSelector : {}
311313 tolerations : []
@@ -334,6 +336,7 @@ server:
334336 deploymentStrategy : {}
335337 podAnnotations : {}
336338 podLabels : {}
339+ serviceLabels : {}
337340 resources : {}
338341 nodeSelector : {}
339342 tolerations : []
@@ -362,6 +365,7 @@ server:
362365 deploymentStrategy : {}
363366 podAnnotations : {}
364367 podLabels : {}
368+ serviceLabels : {}
365369 resources : {}
366370 nodeSelector : {}
367371 tolerations : []
@@ -390,6 +394,7 @@ server:
390394 deploymentStrategy : {}
391395 podAnnotations : {}
392396 podLabels : {}
397+ serviceLabels : {}
393398 resources : {}
394399 nodeSelector : {}
395400 tolerations : []
You can’t perform that action at this time.
0 commit comments