From b374990c794cb62fc510a15efd66e31f45f92b4d Mon Sep 17 00:00:00 2001 From: Krish Dholakia Date: Mon, 9 Sep 2024 14:17:44 -0700 Subject: [PATCH] build(deployment.yaml): Fix port + allow setting database url in helm chart (#5587) --- deploy/charts/litellm-helm/templates/deployment.yaml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/deploy/charts/litellm-helm/templates/deployment.yaml b/deploy/charts/litellm-helm/templates/deployment.yaml index 162cb8286beb..6d63a5110241 100644 --- a/deploy/charts/litellm-helm/templates/deployment.yaml +++ b/deploy/charts/litellm-helm/templates/deployment.yaml @@ -104,7 +104,7 @@ spec: imagePullPolicy: {{ .Values.image.pullPolicy }} env: - name: HOST - value: "::" + value: "{{ .Values.listen | default "0.0.0.0" }}" - name: PORT value: {{ .Values.service.port | quote}} {{- if .Values.db.deployStandalone }} @@ -138,8 +138,13 @@ spec: - name: DATABASE_NAME value: {{ .Values.db.database }} {{- end }} + {{- if .Values.database.url }} + - name: DATABASE_URL + value: {{ .Values.database.url | quote }} + {{- else }} - name: DATABASE_URL value: "postgresql://$(DATABASE_USERNAME):$(DATABASE_PASSWORD)@$(DATABASE_HOST)/$(DATABASE_NAME)" + {{- end }} - name: PROXY_MASTER_KEY valueFrom: secretKeyRef: @@ -231,4 +236,4 @@ spec: {{- with .Values.tolerations }} tolerations: {{- toYaml . | nindent 8 }} - {{- end }} + {{- end }} \ No newline at end of file