-
Notifications
You must be signed in to change notification settings - Fork 2.7k
/
svc.yaml
40 lines (39 loc) · 930 Bytes
/
svc.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
{{- if and .Values.global.prometheus.enabled (.Values.global.prometheus.serviceMonitor.enabled) }}
kind: Service
apiVersion: v1
metadata:
name: cilium-agent
namespace: {{ .Release.Namespace }}
labels:
k8s-app: cilium
spec:
clusterIP: None
type: ClusterIP
ports:
- name: metrics
port: {{ .Values.global.prometheus.port }}
protocol: TCP
targetPort: prometheus
selector:
k8s-app: cilium
{{- end }}
{{- if and .Values.global.hubble.metrics.enabled (.Values.global.hubble.metrics.serviceMonitor.enabled) }}
---
kind: Service
apiVersion: v1
metadata:
name: hubble-metrics
namespace: {{ .Release.Namespace }}
labels:
k8s-app: hubble
spec:
clusterIP: None
type: ClusterIP
ports:
- name: hubble-metrics
port: {{ regexReplaceAll ":([0-9]+)$" .Values.global.hubble.metricsServer "${1}" }}
protocol: TCP
targetPort: hubble-metrics
selector:
k8s-app: cilium
{{- end }}