Skip to content

Commit

Permalink
Merge pull request #48 from Nold360/feat/envsecret
Browse files Browse the repository at this point in the history
feat: env variables from secrets
  • Loading branch information
mudler authored Jul 3, 2024
2 parents 1fbf70e + 096ae83 commit d064a61
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion charts/local-ai/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ appVersion: 1.40
description: A Helm chart for deploying LocalAI to a Kubernetes cluster
name: local-ai
type: application
version: 3.2.0
version: 3.3.0
3 changes: 3 additions & 0 deletions charts/local-ai/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -242,6 +242,9 @@ spec:
{{- end }}
- name: MODELS_PATH
value: {{ .Values.deployment.modelsPath }}
{{- if .Values.deployment.secretEnv }}
{{- toYaml .Values.deployment.secretEnv | nindent 12 }}
{{- end}}
volumeMounts:
{{- range $key, $pvc := $rootPersistence}}
{{- if $pvc.enabled }}
Expand Down
9 changes: 9 additions & 0 deletions charts/local-ai/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,15 @@ deployment:
env:
threads: 4
context_size: 512

# # Inject Secrets into Environment:
# secretEnv:
# - name: HF_TOKEN
# valueFrom:
# secretKeyRef:
# name: some-secret
# key: hf-token

modelsPath: "/models"
download_model:
# To use cloud provided (eg AWS) image, provide it like: 1234356789.dkr.ecr.us-REGION-X.amazonaws.com/busybox
Expand Down

0 comments on commit d064a61

Please sign in to comment.