github.com/verrazzano/verrazzano@v1.7.0/platform-operator/thirdparty/charts/prometheus-community/kube-prometheus-stack/templates/prometheus/serviceThanosSidecar.yaml (about) 1 {{- if and .Values.prometheus.enabled .Values.prometheus.thanosService.enabled (eq .Values.prometheus.thanos.integration "sidecar") }} 2 apiVersion: v1 3 kind: Service 4 metadata: 5 name: {{ template "kube-prometheus-stack.fullname" . }}-thanos-discovery 6 namespace: {{ template "kube-prometheus-stack.namespace" . }} 7 labels: 8 app: {{ template "kube-prometheus-stack.name" . }}-thanos-discovery 9 {{ include "kube-prometheus-stack.labels" . | indent 4 }} 10 {{- if .Values.prometheus.thanosService.labels }} 11 {{ toYaml .Values.prometheus.thanosService.labels | indent 4 }} 12 {{- end }} 13 {{- if .Values.prometheus.thanosService.annotations }} 14 annotations: 15 {{ toYaml .Values.prometheus.thanosService.annotations | indent 4 }} 16 {{- end }} 17 spec: 18 type: {{ .Values.prometheus.thanosService.type }} 19 clusterIP: {{ .Values.prometheus.thanosService.clusterIP }} 20 {{- if ne .Values.prometheus.thanosService.type "ClusterIP" }} 21 externalTrafficPolicy: {{ .Values.prometheus.thanosService.externalTrafficPolicy }} 22 {{- end }} 23 ports: 24 - name: {{ .Values.prometheus.thanosService.portName }} 25 port: {{ .Values.prometheus.thanosService.port }} 26 targetPort: {{ .Values.prometheus.thanosService.targetPort }} 27 {{- if eq .Values.prometheus.thanosService.type "NodePort" }} 28 nodePort: {{ .Values.prometheus.thanosService.nodePort }} 29 {{- end }} 30 - name: {{ .Values.prometheus.thanosService.httpPortName }} 31 port: {{ .Values.prometheus.thanosService.httpPort }} 32 targetPort: {{ .Values.prometheus.thanosService.targetHttpPort }} 33 {{- if eq .Values.prometheus.thanosService.type "NodePort" }} 34 nodePort: {{ .Values.prometheus.thanosService.httpNodePort }} 35 {{- end }} 36 selector: 37 app.kubernetes.io/name: prometheus 38 prometheus: {{ template "kube-prometheus-stack.prometheus.crname" . }} 39 {{- end }}