cephfs: expose csi metrics of sidecars

Expose csi metrics of sidecars deployed by cephfs driver

Signed-off-by: Nikhil-Ladha <nikhilladha1999@gmail.com>
This commit is contained in:
Nikhil-Ladha 2024-10-04 12:21:23 +05:30 committed by mergify[bot]
parent 396a475909
commit dfd8550667
4 changed files with 96 additions and 10 deletions

View File

@ -148,18 +148,21 @@ charts and their default values.
| `provisioner.provisioner.image.repository` | Specifies the csi-provisioner image repository URL | `registry.k8s.io/sig-storage/csi-provisioner` | | `provisioner.provisioner.image.repository` | Specifies the csi-provisioner image repository URL | `registry.k8s.io/sig-storage/csi-provisioner` |
| `provisioner.provisioner.image.tag` | Specifies image tag | `v5.0.1` | | `provisioner.provisioner.image.tag` | Specifies image tag | `v5.0.1` |
| `provisioner.provisioner.image.pullPolicy` | Specifies pull policy | `IfNotPresent` | | `provisioner.provisioner.image.pullPolicy` | Specifies pull policy | `IfNotPresent` |
| `provisioner.provisioner.image.extraArgs` | Specifies extra arguments for the provisioner sidecar | `[]` | | `provisioner.provisioner.args.httpEndpointPort` | Specifies http server port for diagnostics, health checks and metrics | `""` |
| `provisioner.provisioner.extraArgs` | Specifies extra arguments for the provisioner sidecar | `[]` |
| `provisioner.resizer.name` | Specifies the name of csi-resizer sidecar | `resizer` |
| `provisioner.resizer.enabled` | Specifies whether resizer sidecar is enabled | `true` |
| `provisioner.resizer.image.repository` | Specifies the csi-resizer image repository URL | `registry.k8s.io/sig-storage/csi-resizer` | | `provisioner.resizer.image.repository` | Specifies the csi-resizer image repository URL | `registry.k8s.io/sig-storage/csi-resizer` |
| `provisioner.resizer.image.tag` | Specifies image tag | `v1.11.1` | | `provisioner.resizer.image.tag` | Specifies image tag | `v1.11.1` |
| `provisioner.resizer.image.pullPolicy` | Specifies pull policy | `IfNotPresent` | | `provisioner.resizer.image.pullPolicy` | Specifies pull policy | `IfNotPresent` |
| `provisioner.resizer.image.extraArgs` | Specifies extra arguments for the resizer sidecar | `[]` | | `provisioner.resizer.args.httpEndpointPort` | Specifies http server port for diagnostics, health checks and metrics | `""` |
| `provisioner.resizer.name` | Specifies the name of csi-resizer sidecar | `resizer` | | `provisioner.resizer.extraArgs` | Specifies extra arguments for the resizer sidecar | `[]` |
| `provisioner.resizer.enabled` | Specifies whether resizer sidecar is enabled | `true` |
| `provisioner.snapshotter.image.repository` | Specifies the csi-snapshotter image repository URL | `registry.k8s.io/sig-storage/csi-snapshotter` | | `provisioner.snapshotter.image.repository` | Specifies the csi-snapshotter image repository URL | `registry.k8s.io/sig-storage/csi-snapshotter` |
| `provisioner.snapshotter.image.tag` | Specifies image tag | `v8.0.1` | | `provisioner.snapshotter.image.tag` | Specifies image tag | `v8.0.1` |
| `provisioner.snapshotter.image.pullPolicy` | Specifies pull policy | `IfNotPresent` | | `provisioner.snapshotter.image.pullPolicy` | Specifies pull policy | `IfNotPresent` |
| `provisioner.snapshotter.image.extraArgs` | Specifies extra arguments for the snapshotter sidecar | `[]` | | `provisioner.snapshotter.args.enableVolumeGroupSnapshots` | enables the creation of volume group snapshots | `false` |
| `provisioner.snapshotter.args.enableVolumeGroupSnapshots` | enables the creation of volume group snapshots | `false` | | `provisioner.snapshotter.args.httpEndpointPort` | Specifies http server port for diagnostics, health checks and metrics | `""` |
| `provisioner.snapshotter.extraArgs` | Specifies extra arguments for the snapshotter sidecar | `[]` |
| `provisioner.nodeSelector` | Specifies the node selector for provisioner deployment | `{}` | | `provisioner.nodeSelector` | Specifies the node selector for provisioner deployment | `{}` |
| `provisioner.tolerations` | Specifies the tolerations for provisioner deployment | `{}` | | `provisioner.tolerations` | Specifies the tolerations for provisioner deployment | `{}` |
| `provisioner.affinity` | Specifies the affinity for provisioner deployment | `{}` | | `provisioner.affinity` | Specifies the affinity for provisioner deployment | `{}` |

View File

@ -136,12 +136,25 @@ spec:
- "--extra-create-metadata=true" - "--extra-create-metadata=true"
- "--feature-gates=HonorPVReclaimPolicy=true" - "--feature-gates=HonorPVReclaimPolicy=true"
- "--prevent-volume-mode-conversion=true" - "--prevent-volume-mode-conversion=true"
{{- if and .Values.provisioner.provisioner.args .Values.provisioner.provisioner.args.httpEndpointPort }}
- "--http-endpoint=$(POD_IP):{{ .Values.provisioner.provisioner.args.httpEndpointPort }}"
{{- end }}
{{- range .Values.provisioner.provisioner.extraArgs }} {{- range .Values.provisioner.provisioner.extraArgs }}
- "--{{ . }}" - "--{{ . }}"
{{- end }} {{- end }}
env: env:
- name: ADDRESS - name: ADDRESS
value: "unix:///csi/{{ .Values.provisionerSocketFile }}" value: "unix:///csi/{{ .Values.provisionerSocketFile }}"
{{- if and .Values.provisioner.provisioner.args .Values.provisioner.provisioner.args.httpEndpointPort }}
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
ports:
- containerPort: {{ .Values.provisioner.provisioner.args.httpEndpointPort }}
name: http-endpoint
protocol: TCP
{{- end }}
volumeMounts: volumeMounts:
- name: socket-dir - name: socket-dir
mountPath: /csi mountPath: /csi
@ -157,12 +170,25 @@ spec:
- "--leader-election=true" - "--leader-election=true"
- "--extra-create-metadata=true" - "--extra-create-metadata=true"
- "--enable-volume-group-snapshots={{.Values.provisioner.snapshotter.args.enableVolumeGroupSnapshots }}" - "--enable-volume-group-snapshots={{.Values.provisioner.snapshotter.args.enableVolumeGroupSnapshots }}"
{{- if and .Values.provisioner.snapshotter.args .Values.provisioner.snapshotter.args.httpEndpointPort }}
- "--http-endpoint=$(POD_IP):{{ .Values.provisioner.snapshotter.args.httpEndpointPort }}"
{{- end }}
{{- range .Values.provisioner.snapshotter.extraArgs }} {{- range .Values.provisioner.snapshotter.extraArgs }}
- "--{{ . }}" - "--{{ . }}"
{{- end }} {{- end }}
env: env:
- name: ADDRESS - name: ADDRESS
value: "unix:///csi/{{ .Values.provisionerSocketFile }}" value: "unix:///csi/{{ .Values.provisionerSocketFile }}"
{{- if and .Values.provisioner.snapshotter.args .Values.provisioner.snapshotter.args.httpEndpointPort }}
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
ports:
- containerPort: {{ .Values.provisioner.snapshotter.args.httpEndpointPort }}
name: http-endpoint
protocol: TCP
{{- end }}
volumeMounts: volumeMounts:
- name: socket-dir - name: socket-dir
mountPath: /csi mountPath: /csi
@ -180,12 +206,25 @@ spec:
- "--retry-interval-start=500ms" - "--retry-interval-start=500ms"
- "--handle-volume-inuse-error=false" - "--handle-volume-inuse-error=false"
- "--feature-gates=RecoverVolumeExpansionFailure=true" - "--feature-gates=RecoverVolumeExpansionFailure=true"
{{- if and .Values.provisioner.resizer.args .Values.provisioner.resizer.args.httpEndpointPort }}
- "--http-endpoint=$(POD_IP):{{ .Values.provisioner.resizer.args.httpEndpointPort }}"
{{- end }}
{{- range .Values.provisioner.resizer.extraArgs }} {{- range .Values.provisioner.resizer.extraArgs }}
- "--{{ . }}" - "--{{ . }}"
{{- end }} {{- end }}
env: env:
- name: ADDRESS - name: ADDRESS
value: "unix:///csi/{{ .Values.provisionerSocketFile }}" value: "unix:///csi/{{ .Values.provisionerSocketFile }}"
{{- if and .Values.provisioner.resizer.args .Values.provisioner.resizer.args.httpEndpointPort }}
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
ports:
- containerPort: {{ .Values.provisioner.resizer.args.httpEndpointPort }}
name: http-endpoint
protocol: TCP
{{- end }}
volumeMounts: volumeMounts:
- name: socket-dir - name: socket-dir
mountPath: /csi mountPath: /csi

View File

@ -210,6 +210,11 @@ provisioner:
tag: v5.0.1 tag: v5.0.1
pullPolicy: IfNotPresent pullPolicy: IfNotPresent
resources: {} resources: {}
args:
# # httpEndpointPort specifies the http server port for
# # diagnostics, health checks and metrics.
# # Uncomment below line to enable the `http-endpoint` arg for sidecar
# httpEndpointPort: 8090
## For further options, check ## For further options, check
## https://github.com/kubernetes-csi/external-provisioner#command-line-options ## https://github.com/kubernetes-csi/external-provisioner#command-line-options
extraArgs: [] extraArgs: []
@ -225,6 +230,11 @@ provisioner:
tag: v1.11.1 tag: v1.11.1
pullPolicy: IfNotPresent pullPolicy: IfNotPresent
resources: {} resources: {}
args:
# # httpEndpointPort specifies the http server port for
# # diagnostics, health checks and metrics.
# # Uncomment below line to enable the `http-endpoint` arg for sidecar
# httpEndpointPort: 8091
## For further options, check ## For further options, check
## https://github.com/kubernetes-csi/external-resizer#recommended-optional-arguments ## https://github.com/kubernetes-csi/external-resizer#recommended-optional-arguments
extraArgs: [] extraArgs: []
@ -235,13 +245,16 @@ provisioner:
tag: v8.0.1 tag: v8.0.1
pullPolicy: IfNotPresent pullPolicy: IfNotPresent
resources: {} resources: {}
## For further options, check
## https://github.com/kubernetes-csi/external-snapshotter#csi-external-snapshotter-sidecar-command-line-options
extraArgs: []
args: args:
# enableVolumeGroupSnapshots enables support for volume group snapshots # enableVolumeGroupSnapshots enables support for volume group snapshots
enableVolumeGroupSnapshots: false enableVolumeGroupSnapshots: false
# httpEndpointPort specifies the http server port for
# diagnostics, health checks and metrics.
# Uncomment below line to enable the `http-endpoint` arg for sidecar
# httpEndpointPort: 8092
## For further options, check
## https://github.com/kubernetes-csi/external-snapshotter#csi-external-snapshotter-sidecar-command-line-options
extraArgs: []
nodeSelector: {} nodeSelector: {}

View File

@ -102,10 +102,19 @@ spec:
- "--feature-gates=HonorPVReclaimPolicy=true" - "--feature-gates=HonorPVReclaimPolicy=true"
- "--prevent-volume-mode-conversion=true" - "--prevent-volume-mode-conversion=true"
- "--extra-create-metadata=true" - "--extra-create-metadata=true"
- "--http-endpoint=$(POD_IP):8090"
env: env:
- name: ADDRESS - name: ADDRESS
value: unix:///csi/csi-provisioner.sock value: unix:///csi/csi-provisioner.sock
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
imagePullPolicy: "IfNotPresent" imagePullPolicy: "IfNotPresent"
ports:
- containerPort: 8090
name: http-endpoint
protocol: TCP
volumeMounts: volumeMounts:
- name: socket-dir - name: socket-dir
mountPath: /csi mountPath: /csi
@ -119,10 +128,19 @@ spec:
- "--retry-interval-start=500ms" - "--retry-interval-start=500ms"
- "--handle-volume-inuse-error=false" - "--handle-volume-inuse-error=false"
- "--feature-gates=RecoverVolumeExpansionFailure=true" - "--feature-gates=RecoverVolumeExpansionFailure=true"
- "--http-endpoint=$(POD_IP):8091"
env: env:
- name: ADDRESS - name: ADDRESS
value: unix:///csi/csi-provisioner.sock value: unix:///csi/csi-provisioner.sock
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
imagePullPolicy: "IfNotPresent" imagePullPolicy: "IfNotPresent"
ports:
- containerPort: 8091
name: http-endpoint
protocol: TCP
volumeMounts: volumeMounts:
- name: socket-dir - name: socket-dir
mountPath: /csi mountPath: /csi
@ -135,10 +153,19 @@ spec:
- "--leader-election=true" - "--leader-election=true"
- "--extra-create-metadata=true" - "--extra-create-metadata=true"
- "--enable-volume-group-snapshots=true" - "--enable-volume-group-snapshots=true"
- "--http-endpoint=$(POD_IP):8092"
env: env:
- name: ADDRESS - name: ADDRESS
value: unix:///csi/csi-provisioner.sock value: unix:///csi/csi-provisioner.sock
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
imagePullPolicy: "IfNotPresent" imagePullPolicy: "IfNotPresent"
ports:
- containerPort: 8092
name: http-endpoint
protocol: TCP
volumeMounts: volumeMounts:
- name: socket-dir - name: socket-dir
mountPath: /csi mountPath: /csi
@ -158,6 +185,10 @@ spec:
valueFrom: valueFrom:
fieldRef: fieldRef:
fieldPath: status.podIP fieldPath: status.podIP
ports:
- containerPort: 8681
name: http-metrics
protocol: TCP
volumeMounts: volumeMounts:
- name: socket-dir - name: socket-dir
mountPath: /csi mountPath: /csi