feat(volumes): add the ability to specify volumes and mounts.

This commit is contained in:
Justin Bertrand 2024-10-16 10:21:10 -04:00
parent 645edec699
commit f93c4949c9
2 changed files with 29 additions and 1 deletions

View File

@ -47,6 +47,9 @@ spec:
volumeMounts:
- name: data
mountPath: /tmp/app-data
{{- with .Values.volumeMounts.initContainer }}
{{- toYaml . | nindent 10 }}
{{- end }}
enableServiceLinks: false
automountServiceAccountToken: false
{{- with .Values.podSecurityContext }}
@ -72,6 +75,9 @@ spec:
volumeMounts:
- name: data
mountPath: /app/backend/data
{{- with .Values.volumeMounts.container }}
{{- toYaml . | nindent 10 }}
{{- end }}
env:
{{- if or .Values.ollamaUrls .Values.ollama.enabled }}
- name: "OLLAMA_BASE_URLS"
@ -119,3 +125,6 @@ spec:
persistentVolumeClaim:
claimName: {{ include "open-webui.name" . }}
{{- end }}
{{- with .Values.volumes }}
{{- toYaml . | nindent 8 }}
{{- end }}

View File

@ -93,7 +93,7 @@ service:
openaiBaseApiUrl: ""
# -- Env vars added to the Open WebUI deployment. Most up-to-date environment variables can be found here: https://docs.openwebui.com/getting-started/env-configuration/
extraEnvVars:
extraEnvVars:
# -- Default API key value for Pipelines. Should be updated in a production deployment, or be changed to the required API key if not using Pipelines
- name: OPENAI_API_KEY
value: "0p3n-w3bu!"
@ -109,6 +109,25 @@ extraEnvVars:
# - name: OLLAMA_DEBUG
# value: "1"
# -- Configure container volume mounts
# ref: <https://kubernetes.io/docs/tasks/configure-pod-container/configure-volume-storage/>
volumeMounts:
initContainer: []
# - name: ""
# mountPath: ""
container: []
# - name: ""
# mountPath: ""
# -- Configure pod volumes
# ref: <https://kubernetes.io/docs/tasks/configure-pod-container/configure-volume-storage/>
volumes: []
# - name: ""
# configMap:
# name: ""
# - name: ""
# emptyDir: {}
# -- Configure pod security context
# ref: <https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-containe>
podSecurityContext: