Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions charts/open-webui/templates/NOTES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ This interface allows you to easily interact with local AI models.
Access via ClusterIP service:

export LOCAL_PORT=8080
export POD_NAME=$(kubectl get pods -n {{ .Release.Namespace }} -l "app.kubernetes.io/component={{ include "open-webui.name" . }}" -o jsonpath="{.items[0].metadata.name}")
export POD_NAME=$(kubectl get pods -n {{ .Release.Namespace }} -l "app.kubernetes.io/component={{ include "open-webui.fullname" . }}" -o jsonpath="{.items[0].metadata.name}")
export CONTAINER_PORT=$(kubectl get pod -n {{ .Release.Namespace }} $POD_NAME -o jsonpath="{.spec.containers[0].ports[0].containerPort}")
kubectl -n {{ .Release.Namespace }} port-forward $POD_NAME $LOCAL_PORT:$CONTAINER_PORT
echo "Visit http://127.0.0.1:$LOCAL_PORT to use your application"
Expand All @@ -36,7 +36,7 @@ This interface allows you to easily interact with local AI models.

{{- else if contains "NodePort" .Values.service.type }}
Access via NodePort service:
export NODE_PORT=$(kubectl get -n {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "open-webui.name" . }})
export NODE_PORT=$(kubectl get -n {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "open-webui.fullname" . }})
export NODE_IP=$(kubectl get nodes -o jsonpath="{.items[0].status.addresses[0].address}")
echo http://$NODE_IP:$NODE_PORT

Expand All @@ -48,8 +48,8 @@ This interface allows you to easily interact with local AI models.
- GCP/Azure: Will return an IP address
You can watch the status by running:

kubectl get -n {{ .Release.Namespace }} svc {{ include "open-webui.name" . }} --watch
export EXTERNAL_IP=$(kubectl get -n {{ .Release.Namespace }} svc {{ include "open-webui.name" . }} -o jsonpath="{.status.loadBalancer.ingress[0].hostname:-.status.loadBalancer.ingress[0].ip}")
kubectl get -n {{ .Release.Namespace }} svc {{ include "open-webui.fullname" . }} --watch
export EXTERNAL_IP=$(kubectl get -n {{ .Release.Namespace }} svc {{ include "open-webui.fullname" . }} -o jsonpath="{.status.loadBalancer.ingress[0].hostname:-.status.loadBalancer.ingress[0].ip}")
echo http://$EXTERNAL_IP:{{ .Values.service.port }}
{{- end }}

Expand All @@ -67,9 +67,9 @@ This interface allows you to easily interact with local AI models.

- View logs:
{{- if .Values.persistence.enabled }}
kubectl logs -f statefulset/{{ include "open-webui.name" . }} -n {{ .Release.Namespace }}
kubectl logs -f statefulset/{{ include "open-webui.fullname" . }} -n {{ .Release.Namespace }}
{{- else }}
kubectl logs -f deployment/{{ include "open-webui.name" . }} -n {{ .Release.Namespace }}
kubectl logs -f deployment/{{ include "open-webui.fullname" . }} -n {{ .Release.Namespace }}
{{- end }}

4. Cleanup:
Expand Down
18 changes: 18 additions & 0 deletions charts/open-webui/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,24 @@ Set the name of the Open WebUI resources
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
{{- end -}}

{{/*
Create a default fully qualified app name.
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
If release name contains chart name it will be used as a full name.
*/}}
{{- define "open-webui.fullname" -}}
{{- if .Values.fullnameOverride -}}
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
{{- else -}}
{{- $name := default .Chart.Name .Values.nameOverride -}}
{{- if contains $name .Release.Name -}}
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
{{- else -}}
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
{{- end -}}
{{- end -}}
{{- end -}}

{{/*
Set the name of the integrated Ollama resources
*/}}
Expand Down
8 changes: 4 additions & 4 deletions charts/open-webui/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: {{ include "open-webui.name" . }}
name: {{ include "open-webui.fullname" . }}
namespace: {{ include "open-webui.namespace" . }}
labels:
{{- include "open-webui.labels" . | nindent 4 }}
Expand All @@ -24,7 +24,7 @@ spec:
{{- range .Values.ingress.additionalHosts }}
- {{ . | quote }}
{{- end }}
secretName: {{ default (printf "%s-tls" .Release.Name) .Values.ingress.existingSecret }}
secretName: {{ default (printf "%s-tls" (include "open-webui.fullname" .)) .Values.ingress.existingSecret }}
{{- end }}
rules:
- host: {{ .Values.ingress.host }}
Expand All @@ -34,7 +34,7 @@ spec:
pathType: Prefix
backend:
service:
name: {{ include "open-webui.name" . }}
name: {{ include "open-webui.fullname" . }}
port:
name: http
{{- range .Values.ingress.additionalHosts }}
Expand All @@ -45,7 +45,7 @@ spec:
pathType: Prefix
backend:
service:
name: {{ include "open-webui.name" $ }}
name: {{ include "open-webui.fullname" $ }}
port:
name: http
{{- end }}
Expand Down
2 changes: 1 addition & 1 deletion charts/open-webui/templates/pvc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: {{ include "open-webui.name" . }}
name: {{ include "open-webui.fullname" . }}
namespace: {{ include "open-webui.namespace" . }}
labels:
{{- include "open-webui.selectorLabels" . | nindent 4 }}
Expand Down
4 changes: 2 additions & 2 deletions charts/open-webui/templates/service-account.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: v1
kind: ServiceAccount
metadata:
name: {{ .Values.serviceAccount.name | default (include "open-webui.name" .) }}
name: {{ .Values.serviceAccount.name | default (include "open-webui.fullname" .) }}-sa
namespace: {{ include "open-webui.namespace" . }}
labels:
{{- include "open-webui.labels" . | nindent 4 }}
Expand All @@ -11,4 +11,4 @@ metadata:
{{- toYaml . | nindent 4 }}
{{- end }}
automountServiceAccountToken: {{ .Values.serviceAccount.automountServiceAccountToken }}
{{- end }}
{{- end }}
2 changes: 1 addition & 1 deletion charts/open-webui/templates/service.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v1
kind: Service
metadata:
name: {{ include "open-webui.name" . }}
name: {{ include "open-webui.fullname" . }}
namespace: {{ include "open-webui.namespace" . }}
labels:
{{- include "open-webui.labels" . | nindent 4 }}
Expand Down
6 changes: 3 additions & 3 deletions charts/open-webui/templates/websocket-redis.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ .Values.websocket.redis.name }}
name: {{ include "open-webui.fullname" . }}-redis
namespace: {{ include "open-webui.namespace" . }}
labels:
{{- include "websocket.redis.labels" . | nindent 4 }}
Expand Down Expand Up @@ -34,7 +34,7 @@ spec:
- name: {{ .Values.websocket.redis.image.pullSecretName }}
{{- end }}
containers:
- name: {{ .Values.websocket.redis.name }}
- name: {{ include "open-webui.fullname" . }}-redis
image: "{{ .Values.websocket.redis.image.repository }}:{{ .Values.websocket.redis.image.tag }}"
imagePullPolicy: {{ .Values.websocket.redis.image.pullPolicy }}
{{- with .Values.websocket.redis.command }}
Expand Down Expand Up @@ -72,7 +72,7 @@ spec:
apiVersion: v1
kind: Service
metadata:
name: {{ .Values.websocket.redis.name }}
name: {{ include "open-webui.fullname" . }}-redis
namespace: {{ include "open-webui.namespace" . }}
labels:
{{- include "websocket.redis.labels" . | nindent 4 }}
Expand Down
8 changes: 4 additions & 4 deletions charts/open-webui/templates/workload-manager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ kind: StatefulSet
kind: Deployment
{{- end }}
metadata:
name: {{ include "open-webui.name" . }}
name: {{ include "open-webui.fullname" . }}
namespace: {{ include "open-webui.namespace" . }}
labels:
{{- include "open-webui.labels" . | nindent 4 }}
Expand All @@ -19,7 +19,7 @@ spec:
revisionHistoryLimit: {{ .Values.revisionHistoryLimit }}
{{- end }}
{{- if and .Values.persistence.enabled (eq .Values.persistence.provider "local") }}
serviceName: {{ include "open-webui.name" . }}
serviceName: {{ include "open-webui.fullname" . }}
{{- end }}
selector:
matchLabels:
Expand Down Expand Up @@ -89,7 +89,7 @@ spec:
runtimeClassName: {{ .Values.runtimeClassName | quote }}
{{- end }}
{{- if .Values.serviceAccount.enable }}
serviceAccountName: {{ .Values.serviceAccount.name | default (include "open-webui.name" .) }}
serviceAccountName: {{ .Values.serviceAccount.name | default (include "open-webui.fullname" .) }}-sa
{{- end }}
{{- with .Values.podSecurityContext }}
securityContext:
Expand Down Expand Up @@ -411,7 +411,7 @@ spec:
{{- else if and .Values.persistence.enabled (not .Values.persistence.existingClaim) }}
- name: data
persistentVolumeClaim:
claimName: {{ include "open-webui.name" . }}
claimName: {{ include "open-webui.fullname" . }}
{{- end }}
{{- with .Values.volumes }}
{{- toYaml . | nindent 6 }}
Expand Down
3 changes: 1 addition & 2 deletions charts/open-webui/values.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
nameOverride: ""
fullnameOverride: ""
namespaceOverride: ""
ollama:
# -- Automatically install Ollama Helm chart from https://otwld.github.io/ollama-helm/. Use [Helm Values](https://github.com/otwld/ollama-helm/#helm-values) to configure
Expand Down Expand Up @@ -50,8 +51,6 @@ websocket:
redis:
# -- Enable redis installation
enabled: true
# -- Redis name
name: open-webui-redis
# -- Redis labels
labels: {}
# -- Redis annotations
Expand Down