diff --git a/helm/librechat/templates/configmaps-additional.yaml b/helm/librechat/templates/configmaps-additional.yaml new file mode 100755 index 0000000000..4beb80a8d9 --- /dev/null +++ b/helm/librechat/templates/configmaps-additional.yaml @@ -0,0 +1,26 @@ +{{- range $key, $value := .Values.additionalConfigMaps }} +{{- if or .data .binaryData }} +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "librechat.fullname" $ }}-{{ default "custom" $key }} + {{- with .labels }} + labels: + {{- toYaml . | nindent 4 }} + {{- end }} + {{- with .annotations }} + annotations: + {{- toYaml . | nindent 4 }} + {{- end }} +{{- with .data }} +data: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .binaryData }} +binaryData: + {{- toYaml . | nindent 2 }} +immutable: {{ default false .immutable }} +{{- end }} +{{- end }} +{{- end }} diff --git a/helm/librechat/templates/deployment.yaml b/helm/librechat/templates/deployment.yaml index e046bc507a..f8d0e58298 100755 --- a/helm/librechat/templates/deployment.yaml +++ b/helm/librechat/templates/deployment.yaml @@ -51,6 +51,15 @@ spec: serviceAccountName: {{ include "librechat.serviceAccountName" . }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} + {{- if .Values.initContainers }} + initContainers: + {{- range $key, $value := .Values.initContainers }} + {{- if . }} + - name: {{ $key }} + {{- toYaml . | nindent 10 }} + {{- end }} + {{- end }} + {{- end }} containers: - name: {{ include "librechat.fullname" $ }} securityContext: diff --git a/helm/librechat/values.yaml b/helm/librechat/values.yaml index 2560535504..169604bfe4 100755 --- a/helm/librechat/values.yaml +++ b/helm/librechat/values.yaml @@ -219,6 +219,13 @@ readinessProbe: path: /health port: 3080 +# Additional init containers on the output Deployment definition. +initContainers: {} +# foo: # the name of the init container +# image: busybox +# command: ['sh', '-c', 'echo The app is starting! && sleep 5'] +# # ... add more init containers as needed + # Additional volumes on the output Deployment definition. volumes: [] # - name: foo @@ -269,6 +276,16 @@ dnsConfig: {} updateStrategy: type: RollingUpdate +# Extra ConfigMaps to be created alongside the main ones +additionalConfigMaps: {} +# custom: # suffix of the ConfigMap name +# labels: {} +# annotations: {} +# data: {} +# binaryData: {} +# immutable: false +# # ... add more ConfigMaps as needed + # MongoDB Parameters mongodb: enabled: true