diff --git a/charts/stable/games-on-whales/Chart.yaml b/charts/stable/games-on-whales/Chart.yaml index c586f376..c24bcaff 100644 --- a/charts/stable/games-on-whales/Chart.yaml +++ b/charts/stable/games-on-whales/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v2 appVersion: 1.0.0 description: Streams graphic applications/games (retroarch, firefox, steam) runing on Kubernetes name: games-on-whales -version: 1.2.0 +version: 1.3.0 kubeVersion: ">=1.19.0-0" keywords: - games-on-whales @@ -18,6 +18,8 @@ sources: maintainers: - name: angelnu email: gits@angelnu.com +- name: ABeltramo + email: beltramo.ale@gmail.com dependencies: - name: common repository: https://library-charts.k8s-at-home.com diff --git a/charts/stable/games-on-whales/README.md b/charts/stable/games-on-whales/README.md index af7317c2..a83be71f 100644 --- a/charts/stable/games-on-whales/README.md +++ b/charts/stable/games-on-whales/README.md @@ -1,6 +1,6 @@ # games-on-whales -![Version: 1.2.0](https://img.shields.io/badge/Version-1.2.0-informational?style=flat-square) ![AppVersion: 1.0.0](https://img.shields.io/badge/AppVersion-1.0.0-informational?style=flat-square) +![Version: 1.3.0](https://img.shields.io/badge/Version-1.3.0-informational?style=flat-square) ![AppVersion: 1.0.0](https://img.shields.io/badge/AppVersion-1.0.0-informational?style=flat-square) Streams graphic applications/games (retroarch, firefox, steam) runing on Kubernetes @@ -67,7 +67,34 @@ helm install games-on-whales k8s-at-home/games-on-whales -f values.yaml ## Custom configuration -You need a real graphic card in your Kubernetes node to run Games on Whales. +### GPU + +You need a real graphic card in your Kubernetes node to run Games on Whales: + +#### Intel + +It does not require any custom settings but if you use [intel-gpu-plugin](https://github.com/k8s-at-home/charts/tree/master/charts/stable/intel-gpu-plugin) +then you might use the `graphic_resources` value to specify the resource limits +such as: + +``` +graphic_resources: + gpu.intel.com/i915: 1 # requesting 1 i915 GPU +``` + +#### Nvidia + +If you use the Nvidia propietary device driver then you will need the +[Nvidia device plugin](https://github.com/NVIDIA/k8s-device-plugin) +and set `graphic_resources` value to specify the resource limits. +Example: + +``` +graphic_resources: + nvidia.com/gpu: 1 # requesting 1 nvidia GPU +``` + +#### Proxmox If you use Proxmox you might use PCI pass-through but you also need to ensure the host does not load any modules for the graphic card. See the @@ -85,6 +112,7 @@ the host does not load any modules for the graphic card. See the | firefox.image.tag | string | `"91.0.2-r1"` | image tag | | firefox.logLevel | string | `"info"` | firefox log level | | firefox.volumeMounts | list | `[]` | firefox extra volume mounts | +| graphic_resources | object | `nil` | Pass GPU resources to Xorg, steam and retroarch containers See Custom configuration section in the Readme | | ingress.main | object | See values.yaml | Enable and configure ingress settings for the chart under this key. | | mkhomeretrodirs.image.pullPolicy | string | `"IfNotPresent"` | image pull policy | | mkhomeretrodirs.image.repository | string | `"busybox"` | image repository | @@ -128,6 +156,13 @@ All notable changes to this application Helm chart will be documented in this fi The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +### [1.3.0] + +#### Added + +- support for NVIDIA +- ABeltramo as maintainer + ### [1.2.0] #### Changed diff --git a/charts/stable/games-on-whales/README_CHANGELOG.md.gotmpl b/charts/stable/games-on-whales/README_CHANGELOG.md.gotmpl index 12216c2c..b1a747da 100644 --- a/charts/stable/games-on-whales/README_CHANGELOG.md.gotmpl +++ b/charts/stable/games-on-whales/README_CHANGELOG.md.gotmpl @@ -9,6 +9,13 @@ All notable changes to this application Helm chart will be documented in this fi The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +### [1.3.0] + +#### Added + +- support for NVIDIA +- ABeltramo as maintainer + ### [1.2.0] #### Changed diff --git a/charts/stable/games-on-whales/README_CONFIG.md.gotmpl b/charts/stable/games-on-whales/README_CONFIG.md.gotmpl index fd6a6270..e6900763 100644 --- a/charts/stable/games-on-whales/README_CONFIG.md.gotmpl +++ b/charts/stable/games-on-whales/README_CONFIG.md.gotmpl @@ -5,7 +5,35 @@ {{- define "custom.custom.configuration" -}} {{ template "custom.custom.configuration.header" . }} -You need a real graphic card in your Kubernetes node to run Games on Whales. + +### GPU + +You need a real graphic card in your Kubernetes node to run Games on Whales: + +#### Intel + +It does not require any custom settings but if you use [intel-gpu-plugin](https://github.com/k8s-at-home/charts/tree/master/charts/stable/intel-gpu-plugin) +then you might use the `graphic_resources` value to specify the resource limits +such as: + +``` +graphic_resources: + gpu.intel.com/i915: 1 # requesting 1 i915 GPU +``` + +#### Nvidia + +If you use the Nvidia propietary device driver then you will need the +[Nvidia device plugin](https://github.com/NVIDIA/k8s-device-plugin) +and set `graphic_resources` value to specify the resource limits. +Example: + +``` +graphic_resources: + nvidia.com/gpu: 1 # requesting 1 nvidia GPU +``` + +#### Proxmox If you use Proxmox you might use PCI pass-through but you also need to ensure the host does not load any modules for the graphic card. See the diff --git a/charts/stable/games-on-whales/templates/common.yaml b/charts/stable/games-on-whales/templates/common.yaml index e87dbe3b..d1e9582a 100644 --- a/charts/stable/games-on-whales/templates/common.yaml +++ b/charts/stable/games-on-whales/templates/common.yaml @@ -10,6 +10,14 @@ image: securityContext: privileged: true +{{- if .Values.graphic_resources }} +resources: + requests: + {{ .Values.graphic_resources | toYaml | nindent 4 }} + limits: + {{ .Values.graphic_resources | toYaml | nindent 4 }} +{{- end }} + env: DISPLAY: {{ .Values.xorg.display }} LOG_LEVEL: {{ .Values.sunshine.logLevel }} @@ -42,6 +50,13 @@ additionalContainers: imagePullPolicy: {{ .Values.xorg.image.pullPolicy }} securityContext: privileged: true + {{- if .Values.graphic_resources }} + resources: + requests: + {{ .Values.graphic_resources | toYaml | nindent 8 }} + limits: + {{ .Values.graphic_resources | toYaml | nindent 8 }} + {{- end }} env: - name: DISPLAY value: {{ .Values.xorg.display | quote }} @@ -74,6 +89,13 @@ additionalContainers: imagePullPolicy: {{ .Values.retroarch.image.pullPolicy }} securityContext: privileged: true + {{- if .Values.graphic_resources }} + resources: + requests: + {{ .Values.graphic_resources | toYaml | nindent 8 }} + limits: + {{ .Values.graphic_resources | toYaml | nindent 8 }} + {{- end }} env: - name: DISPLAY value: {{ .Values.xorg.display | quote }} @@ -111,6 +133,13 @@ additionalContainers: imagePullPolicy: {{ .Values.steam.image.pullPolicy }} securityContext: privileged: true + {{- if .Values.graphic_resources }} + resources: + requests: + {{ .Values.graphic_resources | toYaml | nindent 8 }} + limits: + {{ .Values.graphic_resources | toYaml | nindent 8 }} + {{- end }} env: - name: DISPLAY value: {{ .Values.xorg.display | quote }} diff --git a/charts/stable/games-on-whales/values.yaml b/charts/stable/games-on-whales/values.yaml index 98821f99..af670288 100644 --- a/charts/stable/games-on-whales/values.yaml +++ b/charts/stable/games-on-whales/values.yaml @@ -32,6 +32,10 @@ persistence: type: emptyDir mountPath: /home/retro +# -- (object) Pass GPU resources to Xorg, steam and retroarch containers +# See Custom configuration section in the Readme +graphic_resources: + sunshine: image: # -- sunshine image repository