Skip to content

Commit

Permalink
fix(CSI-241): conflict in metrics between node and controller
Browse files Browse the repository at this point in the history
  • Loading branch information
sergeyberezansky committed Sep 12, 2024
1 parent cc176e4 commit e819d25
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ spec:
annotations:
prometheus.io/scrape: 'true'
prometheus.io/path: '/metrics'
prometheus.io/port: '{{ .Values.metrics.port | default 9090 }}'
prometheus.io/port: '{{ .Values.metrics.controllerPort | default 9090 }},{{ .Values.metrics.provisionerPort | default 9091 }},{{ .Values.metrics.resizerPort | default 9092 }},{{ .Values.metrics.snapshotterPort | default 9093 }}'
{{- end }}
spec:
{{- if .Values.nodeSelector }}
Expand Down Expand Up @@ -192,7 +192,7 @@ spec:
{{- end }}
{{- if .Values.metrics.enabled }}
- "--enablemetrics"
- "--metricsport={{ .Values.metrics.port | default 9090 }}"
- "--metricsport={{ .Values.metrics.controllerPort | default 9090 }}"
{{- end }}
{{- if .Values.pluginConfig.allowInsecureHttps }}
- "--allowinsecurehttps"
Expand Down Expand Up @@ -229,7 +229,7 @@ spec:
name: healthz
protocol: TCP
{{- if .Values.metrics.enabled }}
- containerPort: {{ .Values.metrics.port }}
- containerPort: {{ .Values.metrics.controllerPort | default 9090 }}
name: metrics
protocol: TCP
{{- end }}
Expand Down
6 changes: 3 additions & 3 deletions charts/csi-wekafsplugin/templates/nodeserver-daemonset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ spec:
annotations:
prometheus.io/scrape: 'true'
prometheus.io/path: '/metrics'
prometheus.io/port: '{{ .Values.metrics.port | default 9090 }}'
prometheus.io/port: '{{ .Values.metrics.nodePort | default 9090 }}'
{{- end }}
spec:
{{- if (eq .Values.selinuxSupport "mixed")}}
Expand Down Expand Up @@ -86,7 +86,7 @@ spec:
{{- end }}
{{- if .Values.metrics.enabled }}
- "--enablemetrics"
- "--metricsport={{ .Values.metrics.port | default 9090 }}"
- "--metricsport={{ .Values.metrics.nodePort | default 9090 }}"
{{- end }}
{{- if .Values.pluginConfig.allowInsecureHttps }}
- "--allowinsecurehttps"
Expand Down Expand Up @@ -120,7 +120,7 @@ spec:
name: healthz
protocol: TCP
{{- if .Values.metrics.enabled }}
- containerPort: {{ .Values.metrics.port }}
- containerPort: {{ .Values.metrics.nodePort }}
name: metrics
protocol: TCP
{{- end }}
Expand Down
6 changes: 4 additions & 2 deletions charts/csi-wekafsplugin/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -96,14 +96,16 @@ kubeletPath: "/var/lib/kubelet"
metrics:
# -- Enable Prometheus Metrics
enabled: true
# -- Metrics port
port: 9090
# -- Metrics port for Controller Server
controllerPort: 9090
# -- Provisioner metrics port
provisionerPort: 9091
# -- Resizer metrics port
resizerPort: 9092
# -- Snapshotter metrics port
snapshotterPort: 9093
# -- Metrics port for Node Serer
nodePort: 9094
# -- Tracing URL (For Jaeger tracing engine / OpenTelemetry), optional
# @ignore
tracingUrl: ""
Expand Down

0 comments on commit e819d25

Please sign in to comment.