Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions charts/kube-ovn-v2/templates/agent/agent-service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@ metadata:
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.agent.labels }}
labels:
app.kubernetes.io/name: kube-ovn-cni
app.kubernetes.io/part-of: kube-ovn
{{- with .Values.agent.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- end }}
spec:
selector:
app.kubernetes.io/name: kube-ovn-cni
Expand Down
28 changes: 28 additions & 0 deletions charts/kube-ovn-v2/templates/agent/agent-servicemonitor.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{{- if .Values.agent.serviceMonitor.enabled }}
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: kube-ovn-cni
namespace: {{ .Values.namespace }}
{{- with .Values.agent.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
labels:
app.kubernetes.io/name: kube-ovn-cni
app.kubernetes.io/part-of: kube-ovn
{{- with .Values.agent.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
endpoints:
- bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
interval: 15s
port: metrics
namespaceSelector:
matchNames:
- {{ .Values.namespace }}
selector:
matchLabels:
app.kubernetes.io/name: kube-ovn-cni
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@ metadata:
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.controller.labels }}
labels:
app.kubernetes.io/name: kube-ovn-controller
app.kubernetes.io/part-of: kube-ovn
{{- with .Values.controller.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- end }}
spec:
selector:
app.kubernetes.io/name: kube-ovn-controller
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{{- if .Values.controller.serviceMonitor.enabled }}
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: kube-ovn-controller
namespace: {{ .Values.namespace }}
{{- with .Values.controller.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
labels:
app.kubernetes.io/name: kube-ovn-controller
app.kubernetes.io/part-of: kube-ovn
{{- with .Values.controller.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
endpoints:
- bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
interval: 15s
port: metrics
namespaceSelector:
matchNames:
- {{ .Values.namespace }}
selector:
matchLabels:
app.kubernetes.io/name: kube-ovn-controller
{{- end }}
6 changes: 4 additions & 2 deletions charts/kube-ovn-v2/templates/monitor/monitor-service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@ metadata:
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.monitor.labels }}
labels:
app.kubernetes.io/name: kube-ovn-monitor
app.kubernetes.io/part-of: kube-ovn
{{- with .Values.monitor.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- end }}
spec:
ports:
- name: metrics
Expand Down
28 changes: 28 additions & 0 deletions charts/kube-ovn-v2/templates/monitor/monitor-servicemonitor.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{{- if .Values.monitor.serviceMonitor.enabled }}
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: kube-ovn-monitor
namespace: {{ .Values.namespace }}
{{- with .Values.monitor.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
labels:
app.kubernetes.io/name: kube-ovn-monitor
app.kubernetes.io/part-of: kube-ovn
{{- with .Values.monitor.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
endpoints:
- bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
interval: 15s
port: metrics
namespaceSelector:
matchNames:
- {{ .Values.namespace }}
selector:
matchLabels:
app.kubernetes.io/name: kube-ovn-monitor
{{- end }}
6 changes: 4 additions & 2 deletions charts/kube-ovn-v2/templates/pinger/pinger-service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@ metadata:
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.pinger.labels }}
labels:
app.kubernetes.io/name: kube-ovn-pinger
app.kubernetes.io/part-of: kube-ovn
{{- with .Values.pinger.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- end }}
spec:
selector:
app.kubernetes.io/name: kube-ovn-pinger
Expand Down
28 changes: 28 additions & 0 deletions charts/kube-ovn-v2/templates/pinger/pinger-servicemonitor.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{{- if .Values.pinger.serviceMonitor.enabled }}
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: kube-ovn-pinger
namespace: {{ .Values.namespace }}
{{- with .Values.pinger.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
labels:
app.kubernetes.io/name: kube-ovn-pinger
app.kubernetes.io/part-of: kube-ovn
{{- with .Values.pinger.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
endpoints:
- bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
interval: 15s
port: metrics
namespaceSelector:
matchNames:
- {{ .Values.namespace }}
selector:
matchLabels:
app.kubernetes.io/name: kube-ovn-pinger
{{- end }}
33 changes: 33 additions & 0 deletions charts/kube-ovn-v2/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -573,6 +573,15 @@ pinger:
# @section -- Ping daemon configuration
port: 8080

# -- Ping daemon serviceMonitor configuration.
# @section -- Ping daemon configuration
# @default -- "{}"
serviceMonitor:
# -- Enable the deployment of the ServiceMonitor for the pinger.
# @section -- Ping daemon configuration
enabled: false

# @section -- OVN monitoring daemon configuration
# -- Remote targets used by the pinger daemon to determine if the CNI works and has external connectivity.
# @section -- Ping daemon configuration
# @default -- "{}"
Expand Down Expand Up @@ -665,6 +674,14 @@ monitor:
# @section -- OVN monitoring daemon configuration
port: 10661

# -- kube-ovn-monitor serviceMonitor configuration.
# @section -- OVN monitoring daemon configuration
# @default -- "{}"
serviceMonitor:
# -- Enable the deployment of the ServiceMonitor for the kube-ovn-monitor.
# @section -- OVN monitoring daemon configuration
enabled: false

# -- Configuration for kube-ovn-controller, the controller responsible for syncing K8s with OVN.
# @section -- Kube-OVN controller configuration
# @default -- "{}"
Expand Down Expand Up @@ -731,6 +748,14 @@ controller:
# @section -- Kube-OVN controller configuration
port: 10660

# -- Controller serviceMonitor configuration.
# @section -- Kube-OVN controller configuration
# @default -- "{}"
serviceMonitor:
# -- Enable the deployment of the ServiceMonitor for the Kube-OVN controller.
# @section -- Kube-OVN controller configuration
enabled: false

# -- Configuration for ovn-central, the daemon containing the northbound/southbound DBs and northd.
# @section -- OVN-central daemon configuration
# @default -- "{}"
Expand Down Expand Up @@ -876,6 +901,14 @@ agent:
# @section -- CNI agent configuration
port: 10665

# -- Agent serviceMonitor configuration.
# @section -- CNI agent configuration
# @default -- "{}"
serviceMonitor:
# -- Enable the deployment of the ServiceMonitor for the agent.
# @section -- CNI agent configuration
enabled: false

# -- Mirroring of the traffic for debug or analysis.
# https://kubeovn.github.io/docs/stable/en/guide/mirror/
# @section -- CNI agent configuration
Expand Down
Loading