Skip to content

Commit

Permalink
Merge pull request #16 from langchain-ai/infra/add-extra-env-vars
Browse files Browse the repository at this point in the history
Add extra env variables support
  • Loading branch information
langchain-infra authored Nov 17, 2023
2 parents 370f3f4 + 79dc839 commit 0854cbc
Show file tree
Hide file tree
Showing 9 changed files with 40 additions and 0 deletions.
3 changes: 3 additions & 0 deletions charts/langsmith/templates/backend/api-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ spec:
value: {{ .Values.backend.containerPort | quote }}
- name: AUTH_TYPE
value: api_key
{{- with .Values.backend.deployment.extraEnv }}
{{- toYaml . | nindent 12 }}
{{- end }}
image: "{{ .Values.images.backendImage.repository }}:{{ .Values.images.backendImage.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.images.backendImage.pullPolicy }}
ports:
Expand Down
3 changes: 3 additions & 0 deletions charts/langsmith/templates/backend/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ spec:
key: openai_api_key
- name: PORT
value: {{ .Values.backend.containerPort | quote }}
{{- with .Values.backend.deployment.extraEnv }}
{{- toYaml . | nindent 12 }}
{{- end }}
image: "{{ .Values.images.backendImage.repository }}:{{ .Values.images.backendImage.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.images.backendImage.pullPolicy }}
ports:
Expand Down
3 changes: 3 additions & 0 deletions charts/langsmith/templates/frontend/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,9 @@ spec:
secretKeyRef:
key: oauth_issuer_url
name: {{ include "langsmith.secretsName" .}}
{{- with .Values.frontend.deployment.extraEnv }}
{{- toYaml . | nindent 12 }}
{{- end }}
image: "{{ .Values.images.frontendImage.repository }}:{{ .Values.images.frontendImage.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.images.frontendImage.pullPolicy }}
ports:
Expand Down
3 changes: 3 additions & 0 deletions charts/langsmith/templates/hub-backend/api-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@ spec:
value: {{ .Values.hubBackend.containerPort | quote }}
- name: AUTH_TYPE
value: 'api_key'
{{- with .Values.hubBackend.deployment.extraEnv }}
{{- toYaml . | nindent 12 }}
{{- end }}
image: "{{ .Values.images.hubBackendImage.repository }}:{{ .Values.images.hubBackendImage.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.images.hubBackendImage.pullPolicy }}
ports:
Expand Down
3 changes: 3 additions & 0 deletions charts/langsmith/templates/hub-backend/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ spec:
{{- include "langsmith.commonEnv" . | nindent 12 }}
- name: PORT
value: {{ .Values.hubBackend.containerPort | quote }}
{{- with .Values.hubBackend.deployment.extraEnv }}
{{- toYaml . | nindent 12 }}
{{- end }}
image: "{{ .Values.images.hubBackendImage.repository }}:{{ .Values.images.hubBackendImage.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.images.hubBackendImage.pullPolicy }}
ports:
Expand Down
4 changes: 4 additions & 0 deletions charts/langsmith/templates/playground/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ spec:
{{- toYaml .Values.playground.deployment.podSecurityContext | nindent 8 }}
containers:
- name: {{ .Values.playground.name }}
{{- with .Values.playground.deployment.extraEnv }}
env:
{{- toYaml . | nindent 12 }}
{{- end }}
image: "{{ .Values.images.playgroundImage.repository }}:{{ .Values.images.playgroundImage.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.images.playgroundImage.pullPolicy }}
ports:
Expand Down
3 changes: 3 additions & 0 deletions charts/langsmith/templates/postgres/stateful-set.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@ spec:
value: postgres
- name: PGDATA
value: /var/lib/postgresql/data/postgres
{{- with .Values.postgres.statefulSet.extraEnv }}
{{- toYaml . | nindent 12 }}
{{- end }}
image: "{{ .Values.images.postgresImage.repository }}:{{ .Values.images.postgresImage.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.images.postgresImage.pullPolicy }}
ports:
Expand Down
4 changes: 4 additions & 0 deletions charts/langsmith/templates/redis/stateful-set.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ spec:
{{- toYaml .Values.redis.statefulSet.podSecurityContext | nindent 8 }}
containers:
- name: {{ .Values.redis.name }}
{{- with .Values.redis.statefulSet.extraEnv }}
env:
{{- toYaml . | nindent 12 }}
{{- end }}
image: "{{ .Values.images.redisImage.repository }}:{{ .Values.images.redisImage.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.images.redisImage.pullPolicy }}
ports:
Expand Down
14 changes: 14 additions & 0 deletions charts/langsmith/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,13 @@ backend:
podSecurityContext: {}
securityContext: {}
resources: {}
# limits:
# cpu: 1000m
# memory: 1Gi
# requests:
# cpu: 200m
# memory: 500Mi
extraEnv: []
nodeSelector: {}
tolerations: []
affinity: {}
Expand All @@ -80,6 +87,7 @@ backend:
# requests:
# cpu: 200m
# memory: 500Mi
extraEnv: []
nodeSelector: {}
tolerations: []
affinity: {}
Expand Down Expand Up @@ -110,6 +118,7 @@ frontend:
# requests:
# cpu: 200m
# memory: 500Mi
extraEnv: []
nodeSelector: {}
tolerations: []
affinity: {}
Expand Down Expand Up @@ -141,6 +150,7 @@ hubBackend:
# requests:
# cpu: 200m
# memory: 500Mi
extraEnv: []
nodeSelector: {}
tolerations: []
affinity: {}
Expand Down Expand Up @@ -171,6 +181,7 @@ playground:
# requests:
# cpu: 200m
# memory: 500Mi
extraEnv: []
nodeSelector: {}
tolerations: []
affinity: {}
Expand Down Expand Up @@ -213,6 +224,7 @@ postgres:
# requests:
# cpu: 1000m
# memory: 4Gi
extraEnv: []
nodeSelector: {}
tolerations: []
affinity: {}
Expand Down Expand Up @@ -241,6 +253,7 @@ queue:
# requests:
# cpu: 200m
# memory: 500Mi
extraEnv: []
nodeSelector: {}
tolerations: []
affinity: {}
Expand Down Expand Up @@ -271,6 +284,7 @@ redis:
# requests:
# cpu: 1000m
# memory: 2Gi
extraEnv: []
nodeSelector: {}
tolerations: []
affinity: {}
Expand Down

0 comments on commit 0854cbc

Please sign in to comment.