Revert "Revert "Jellyfin ohne privileged: GPU über Intel Device Plugin (gpu.intel.com/i915)""
This reverts commit c7e8931e33.
This commit is contained in:
+8
-16
@@ -88,10 +88,6 @@ spec:
|
||||
- name: {{ $name }}
|
||||
image: {{ $app.image }}
|
||||
imagePullPolicy: IfNotPresent
|
||||
{{- if $app.gpu }}
|
||||
securityContext:
|
||||
privileged: true
|
||||
{{- end }}
|
||||
ports:
|
||||
- name: http
|
||||
containerPort: {{ $app.port }}
|
||||
@@ -129,15 +125,17 @@ spec:
|
||||
- name: media
|
||||
mountPath: {{ $root.Values.media.mountPath }}
|
||||
{{- end }}
|
||||
{{- if $app.gpu }}
|
||||
- name: dri
|
||||
mountPath: /dev/dri
|
||||
{{- end }}
|
||||
{{- with $app.resources }}
|
||||
{{- /* gpu: request the iGPU from the Intel GPU device plugin (app intel-gpu-plugin
|
||||
in apps-in-apps). It injects /dev/dri into the container, no privileged needed. */}}
|
||||
{{- $res := deepCopy ($app.resources | default dict) }}
|
||||
{{- if $app.gpu }}
|
||||
{{- $_ := set $res "limits" (merge (dict "gpu.intel.com/i915" 1) (get $res "limits" | default dict)) }}
|
||||
{{- end }}
|
||||
{{- with $res }}
|
||||
resources:
|
||||
{{- toYaml . | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- if or $app.configPath $app.media $app.gpu }}
|
||||
{{- if or $app.configPath $app.media }}
|
||||
volumes:
|
||||
{{- if $app.configPath }}
|
||||
- name: config
|
||||
@@ -150,12 +148,6 @@ spec:
|
||||
path: {{ $root.Values.media.hostPath }}
|
||||
type: DirectoryOrCreate
|
||||
{{- end }}
|
||||
{{- if $app.gpu }}
|
||||
- name: dri
|
||||
hostPath:
|
||||
path: /dev/dri
|
||||
type: Directory
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
---
|
||||
apiVersion: v1
|
||||
|
||||
Reference in New Issue
Block a user