Skip to content

Commit

Permalink
Use default service account for better util metrics (#21)
Browse files Browse the repository at this point in the history
In order for DCGM to be able to collect
GPU utilization correctly, the default service account
needs to be used
  • Loading branch information
atanasovskib authored May 15, 2024
1 parent a5f1954 commit 75982c7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
4 changes: 2 additions & 2 deletions charts/gpu-metrics-exporter/templates/daemonset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ metadata:
ignore-check.kube-linter.io/privileged-container: "This daemon set needs to run DCGM Exporter as privileged to access the GPU metrics."
ignore-check.kube-linter.io/run-as-non-root: "This daemon set needs to run DCGM Exporter as root to access the GPU metrics."
ignore-check.kube-linter.io/privilege-escalation-container: "This daemon set needs escalate privileges for DCGM Exporter to access the GPU metrics."
ignore-check.kube-linter.io/no-read-only-root-fs: "This daemon set needs to run DCGM Exporter with read-only root filesystem to access the GPU utilization metrics."
{{- end }}
spec:
selector:
Expand All @@ -31,7 +32,6 @@ spec:
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
serviceAccountName: {{ include "gpu-metrics-exporter.serviceAccountName" . }}
securityContext:
{{- toYaml .Values.podSecurityContext | nindent 8 }}
volumes:
Expand Down Expand Up @@ -106,7 +106,7 @@ spec:
- name: metrics
containerPort: 9400
securityContext:
{{- toYaml .Values.dcgmExporter.securityContext | nindent 12 }}
privileged: true
env:
- name: NODE_NAME
valueFrom:
Expand Down
3 changes: 0 additions & 3 deletions charts/gpu-metrics-exporter/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,3 @@ dcgmExporter:
tag: 3.3.5-3.4.1-ubuntu22.04
useExternalHostEngine: false
additionalEnv: []
securityContext:
privileged: true
readOnlyRootFilesystem: true

0 comments on commit 75982c7

Please sign in to comment.