Open-source LLM knowledge platform: turn raw documents into a queryable RAG, an autonomous reasoning agent, and a self-maintaining Wiki.
Go agentagenticaichatbotdsh-pluginembeddingsevaluationgenerative-aigolangknowledge-basellmmulti-tenantollamaopenaiquestion-answeringragrerankingsemantic-searchvector-searchwiki
feat(helm): support app.extraVolumes and app.extraVolumeMounts (#4332)
KalandraMo6b981bfef936
diff --git a/helm/README.md b/helm/README.mdindex 4fdc9b404..a27b70470 100644--- a/helm/README.md+++ b/helm/README.md@@ -188,6 +188,45 @@ for the chart's database or other components. Object storage is another optiononly after configuring the provider and checking that all paths needed by yourdeployment are accessible to every replica.+### Mounting Extra Volumes into the App Pod++The chart mounts a single `data-files` volume by default. Use+`app.extraVolumes` and `app.extraVolumeMounts` to attach additional ConfigMaps,+Secrets, PVCs, `emptyDir` or any other volume type to the backend container —+for example a CA bundle, a config file, or a credentials Secret:++```yaml+app:+ extraVolumes:+ - name: ca-bundle+ configMap:+ name: my-ca-bundle+ - name: credentials+ secret:+ secretName: my-credentials+ extraVolumeMounts:+ - name: ca-bundle+ mountPath: /etc/ssl/certs/custom+ readOnly: true+ - name: credentials+ mountPath: /etc/credentials+ readOnly: true+```++Both lists are rendered verbatim, so any field Kubernetes accepts in+`spec.template.spec.volumes` and in a container's `volumeMounts` may be used.++**Requirements and caveats:**++- The referenced ConfigMap, Secret or PVC must already exist in the namespace.+ The chart does not create them.+- Each `name` in `extraVolumeMounts` must match a `name` in `extraVolumes`;+ otherwise the API server rejects the Pod.+- `dataFiles.persistence.enabled` still governs only the built-in `data-files`+ volume. Extra volumes are unaffected by it.+- Verify the rendering before applying:+ `helm template weknora ./helm -f values-production.yaml | grep -A5 extraVolume`+## Configuration### Service names@@ -259,6 +298,8 @@ pre-existing Service name does not automatically transfer its ownership to Helm.| `app.resources` | Resource limits | See values.yaml || `app.env` | Environment variables | See values.yaml || `app.extraEnv` | Additional env vars | `[]` |+| `app.extraVolumes` | Additional Pod volumes (rendered verbatim into `spec.template.spec.volumes`) | `[]` |+| `app.extraVolumeMounts` | Additional volume mounts for the app container (names must match `extraVolumes`) | `[]` |### Data Files Storagediff --git a/helm/templates/app.yaml b/helm/templates/app.yamlindex 07db06c8b..0b50b5cca 100644--- a/helm/templates/app.yaml+++ b/helm/templates/app.yaml@@ -163,6 +163,10 @@ spec:volumeMounts:- name: data-filesmountPath: /data/files+ {{- with .Values.app.extraVolumeMounts }}+ # Additional volume mounts+ {{- toYaml . | nindent 12 }}+ {{- end }}resources:{{- toYaml .Values.app.resources | nindent 12 }}{{- with .Values.app.livenessProbe }}@@ -181,6 +185,10 @@ spec:{{- else }}emptyDir: {}{{- end }}+ {{- with .Values.app.extraVolumes }}+ # Additional volumes+ {{- toYaml . | nindent 8 }}+ {{- end }}{{- with .Values.app.nodeSelector }}nodeSelector:{{- toYaml . | nindent 8 }}diff --git a/helm/values.yaml b/helm/values.yamlindex a4cf1e619..e8ff1ff8e 100644--- a/helm/values.yaml+++ b/helm/values.yaml@@ -159,6 +159,19 @@ app:# -- Affinity rulesaffinity: {}+ # -- Extra volumes for the app pod. Rendered verbatim into spec.template.spec.volumes.+ # Use together with extraVolumeMounts to mount ConfigMaps/Secrets/PVCs into the app container.+ extraVolumes: []+ # - name: my-config+ # configMap:+ # name: my-config++ # -- Extra volume mounts for the app container. Rendered verbatim into the app container's volumeMounts.+ extraVolumeMounts: []+ # - name: my-config+ # mountPath: /etc/my-config+ # readOnly: true+# -----------------------------------------------------------------------------# Frontend (Web UI)# -----------------------------------------------------------------------------