From 3528b46cd89c0978e044dd74c4afe7d232b25ca3 Mon Sep 17 00:00:00 2001 From: romain-priour-lc Date: Wed, 28 May 2025 12:24:49 -0700 Subject: [PATCH 1/4] implementation done --- charts/langsmith/README.md | 1 + charts/langsmith/templates/_helpers.tpl | 12 ++++++++++++ .../langsmith/templates/ace-backend/deployment.yaml | 2 +- .../langsmith/templates/backend/auth-bootstrap.yaml | 2 +- .../templates/backend/clickhouse-migrations.yaml | 2 +- charts/langsmith/templates/backend/deployment.yaml | 2 +- .../templates/backend/postgres-migrations.yaml | 2 +- .../langsmith/templates/clickhouse/stateful-set.yaml | 2 +- charts/langsmith/templates/frontend/deployment.yaml | 2 +- .../langsmith/templates/host-backend/deployment.yaml | 2 +- charts/langsmith/templates/listener/deployment.yaml | 2 +- charts/langsmith/templates/operator/deployment.yaml | 2 +- .../templates/platform-backend/deployment.yaml | 2 +- .../langsmith/templates/playground/deployment.yaml | 2 +- .../langsmith/templates/postgres/stateful-set.yaml | 2 +- charts/langsmith/templates/queue/deployment.yaml | 2 +- .../templates/quickwit/control-plane-deployment.yaml | 2 +- .../templates/quickwit/indexer-stateful-set.yaml | 2 +- .../templates/quickwit/janitor-deployment.yaml | 2 +- .../templates/quickwit/metastore-deployment.yaml | 2 +- .../templates/quickwit/searcher-stateful-set.yaml | 2 +- .../templates/quickwit/update-runs-index-job.yaml | 4 ++-- charts/langsmith/templates/redis/stateful-set.yaml | 2 +- charts/langsmith/values.yaml | 3 ++- 24 files changed, 37 insertions(+), 23 deletions(-) diff --git a/charts/langsmith/README.md b/charts/langsmith/README.md index b3f7f77d..c567ed2c 100644 --- a/charts/langsmith/README.md +++ b/charts/langsmith/README.md @@ -25,6 +25,7 @@ For information on how to use this chart, up-to-date release notes, and other gu | images.clickhouseImage.pullPolicy | string | `"Always"` | | | images.clickhouseImage.repository | string | `"docker.io/clickhouse/clickhouse-server"` | | | images.clickhouseImage.tag | string | `"24.8"` | | +| images.defaultRegistry | string | "" | If supplied, all images will have this registry name concatenated with a `/` | images.frontendImage.pullPolicy | string | `"IfNotPresent"` | | | images.frontendImage.repository | string | `"docker.io/langchain/langsmith-frontend"` | | | images.frontendImage.tag | string | `"0.10.60"` | | diff --git a/charts/langsmith/templates/_helpers.tpl b/charts/langsmith/templates/_helpers.tpl index 89913467..430920a7 100644 --- a/charts/langsmith/templates/_helpers.tpl +++ b/charts/langsmith/templates/_helpers.tpl @@ -609,3 +609,15 @@ checksum/postgres: {{ include (print $.Template.BasePath "/postgres/secrets.yaml checksum/clickhouse: {{ include (print $.Template.BasePath "/clickhouse/secrets.yaml") . | sha256sum }} {{- end }} {{- end }} + +{{/* +Create image reference with registry handling. If defaultRegistry is specified, concatenate with a '/'. +*/}} +{{- define "langsmith.image" -}} +{{- $imageConfig := index .Values.images .component -}} +{{- if .Values.images.defaultRegistry -}} +{{ .Values.images.defaultRegistry }}/{{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} +{{- else -}} +{{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} +{{- end -}} +{{- end -}} \ No newline at end of file diff --git a/charts/langsmith/templates/ace-backend/deployment.yaml b/charts/langsmith/templates/ace-backend/deployment.yaml index e718ff86..4b9dbbd3 100644 --- a/charts/langsmith/templates/ace-backend/deployment.yaml +++ b/charts/langsmith/templates/ace-backend/deployment.yaml @@ -63,7 +63,7 @@ spec: envFrom: - configMapRef: name: {{ include "langsmith.fullname" . }}-config - image: "{{ .Values.images.aceBackendImage.repository }}:{{ .Values.images.aceBackendImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "aceBackendImage") | quote }} imagePullPolicy: {{ .Values.images.aceBackendImage.pullPolicy }} ports: - name: ace diff --git a/charts/langsmith/templates/backend/auth-bootstrap.yaml b/charts/langsmith/templates/backend/auth-bootstrap.yaml index 2e3d0bcf..08dbbeda 100644 --- a/charts/langsmith/templates/backend/auth-bootstrap.yaml +++ b/charts/langsmith/templates/backend/auth-bootstrap.yaml @@ -64,7 +64,7 @@ spec: envFrom: - configMapRef: name: {{ include "langsmith.fullname" . }}-config - image: "{{ .Values.images.backendImage.repository }}:{{ .Values.images.backendImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "backendImage") | quote }} imagePullPolicy: {{ .Values.images.backendImage.pullPolicy }} resources: {{- toYaml .Values.backend.authBootstrap.resources | nindent 12 }} diff --git a/charts/langsmith/templates/backend/clickhouse-migrations.yaml b/charts/langsmith/templates/backend/clickhouse-migrations.yaml index 01a6aae4..74d552d2 100644 --- a/charts/langsmith/templates/backend/clickhouse-migrations.yaml +++ b/charts/langsmith/templates/backend/clickhouse-migrations.yaml @@ -55,7 +55,7 @@ spec: envFrom: - configMapRef: name: {{ include "langsmith.fullname" . }}-config - image: "{{ .Values.images.backendImage.repository }}:{{ .Values.images.backendImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "backendImage") | quote }} imagePullPolicy: {{ .Values.images.backendImage.pullPolicy }} resources: {{- toYaml .Values.backend.clickhouseMigrations.resources | nindent 12 }} diff --git a/charts/langsmith/templates/backend/deployment.yaml b/charts/langsmith/templates/backend/deployment.yaml index b656ea60..ba4c7d2f 100644 --- a/charts/langsmith/templates/backend/deployment.yaml +++ b/charts/langsmith/templates/backend/deployment.yaml @@ -65,7 +65,7 @@ spec: envFrom: - configMapRef: name: {{ include "langsmith.fullname" . }}-config - image: "{{ .Values.images.backendImage.repository }}:{{ .Values.images.backendImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "backendImage") | quote }} imagePullPolicy: {{ .Values.images.backendImage.pullPolicy }} ports: - name: backend diff --git a/charts/langsmith/templates/backend/postgres-migrations.yaml b/charts/langsmith/templates/backend/postgres-migrations.yaml index 8057c214..0a1e5074 100644 --- a/charts/langsmith/templates/backend/postgres-migrations.yaml +++ b/charts/langsmith/templates/backend/postgres-migrations.yaml @@ -55,7 +55,7 @@ spec: envFrom: - configMapRef: name: {{ include "langsmith.fullname" . }}-config - image: "{{ .Values.images.backendImage.repository }}:{{ .Values.images.backendImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "backendImage") | quote }} imagePullPolicy: {{ .Values.images.backendImage.pullPolicy }} resources: {{- toYaml .Values.backend.migrations.resources | nindent 12 }} diff --git a/charts/langsmith/templates/clickhouse/stateful-set.yaml b/charts/langsmith/templates/clickhouse/stateful-set.yaml index 3ceb5b03..e60c4991 100644 --- a/charts/langsmith/templates/clickhouse/stateful-set.yaml +++ b/charts/langsmith/templates/clickhouse/stateful-set.yaml @@ -61,7 +61,7 @@ spec: serviceAccountName: {{ include "clickhouse.serviceAccountName" . }} containers: - name: {{ .Values.clickhouse.name }} - image: "{{ .Values.images.clickhouseImage.repository }}:{{ .Values.images.clickhouseImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "clickhouseImage") | quote }} imagePullPolicy: {{ .Values.images.clickhouseImage.pullPolicy }} {{- with.Values.clickhouse.statefulSet.command }} command: diff --git a/charts/langsmith/templates/frontend/deployment.yaml b/charts/langsmith/templates/frontend/deployment.yaml index 02aab7bb..5606aa06 100644 --- a/charts/langsmith/templates/frontend/deployment.yaml +++ b/charts/langsmith/templates/frontend/deployment.yaml @@ -79,7 +79,7 @@ spec: envFrom: - configMapRef: name: {{ include "langsmith.fullname" . }}-config - image: "{{ .Values.images.frontendImage.repository }}:{{ .Values.images.frontendImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "frontendImage") | quote }} imagePullPolicy: {{ .Values.images.frontendImage.pullPolicy }} ports: - name: frontend diff --git a/charts/langsmith/templates/host-backend/deployment.yaml b/charts/langsmith/templates/host-backend/deployment.yaml index a5a4bc3c..9defe15e 100644 --- a/charts/langsmith/templates/host-backend/deployment.yaml +++ b/charts/langsmith/templates/host-backend/deployment.yaml @@ -62,7 +62,7 @@ spec: envFrom: - configMapRef: name: {{ include "langsmith.fullname" . }}-config - image: "{{ .Values.images.hostBackendImage.repository }}:{{ .Values.images.hostBackendImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "hostBackendImage") | quote }} imagePullPolicy: {{ .Values.images.hostBackendImage.pullPolicy }} ports: - name: host-backend diff --git a/charts/langsmith/templates/listener/deployment.yaml b/charts/langsmith/templates/listener/deployment.yaml index cfa5dec5..70f75044 100644 --- a/charts/langsmith/templates/listener/deployment.yaml +++ b/charts/langsmith/templates/listener/deployment.yaml @@ -66,7 +66,7 @@ spec: envFrom: - configMapRef: name: {{ include "langsmith.fullname" . }}-config - image: "{{ .Values.images.hostBackendImage.repository }}:{{ .Values.images.hostBackendImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "hostBackendImage") | quote }} imagePullPolicy: {{ .Values.images.hostBackendImage.pullPolicy }} {{- with .Values.listener.deployment.startupProbe }} startupProbe: diff --git a/charts/langsmith/templates/operator/deployment.yaml b/charts/langsmith/templates/operator/deployment.yaml index 20bae11c..42a7ed29 100644 --- a/charts/langsmith/templates/operator/deployment.yaml +++ b/charts/langsmith/templates/operator/deployment.yaml @@ -48,7 +48,7 @@ spec: args: - --leader-elect - --health-probe-bind-address=:8081 - image: "{{ .Values.images.operatorImage.repository }}:{{ .Values.images.operatorImage.tag | default "latest" }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "operatorImage") | quote }} imagePullPolicy: {{ .Values.images.operatorImage.pullPolicy }} name: {{ .Values.operator.name }} {{- with .Values.operator.deployment.securityContext }} diff --git a/charts/langsmith/templates/platform-backend/deployment.yaml b/charts/langsmith/templates/platform-backend/deployment.yaml index f7a09500..9d0ea089 100644 --- a/charts/langsmith/templates/platform-backend/deployment.yaml +++ b/charts/langsmith/templates/platform-backend/deployment.yaml @@ -65,7 +65,7 @@ spec: envFrom: - configMapRef: name: {{ include "langsmith.fullname" . }}-config - image: "{{ .Values.images.platformBackendImage.repository }}:{{ .Values.images.platformBackendImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "platformBackendImage") | quote }} imagePullPolicy: {{ .Values.images.platformBackendImage.pullPolicy }} ports: - name: platform diff --git a/charts/langsmith/templates/playground/deployment.yaml b/charts/langsmith/templates/playground/deployment.yaml index 3860b7e1..cd674131 100644 --- a/charts/langsmith/templates/playground/deployment.yaml +++ b/charts/langsmith/templates/playground/deployment.yaml @@ -63,7 +63,7 @@ spec: envFrom: - configMapRef: name: {{ include "langsmith.fullname" . }}-config - image: "{{ .Values.images.playgroundImage.repository }}:{{ .Values.images.playgroundImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "playgroundImage") | quote }} imagePullPolicy: {{ .Values.images.playgroundImage.pullPolicy }} ports: - name: playground diff --git a/charts/langsmith/templates/postgres/stateful-set.yaml b/charts/langsmith/templates/postgres/stateful-set.yaml index a4f85dfb..2b32cf32 100644 --- a/charts/langsmith/templates/postgres/stateful-set.yaml +++ b/charts/langsmith/templates/postgres/stateful-set.yaml @@ -71,7 +71,7 @@ spec: {{- with $envVars }} {{- toYaml . | nindent 12 }} {{- end }} - image: "{{ .Values.images.postgresImage.repository }}:{{ .Values.images.postgresImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "postgresImage") | quote }} imagePullPolicy: {{ .Values.images.postgresImage.pullPolicy }} ports: - name: postgres diff --git a/charts/langsmith/templates/queue/deployment.yaml b/charts/langsmith/templates/queue/deployment.yaml index a6c899d0..36397613 100644 --- a/charts/langsmith/templates/queue/deployment.yaml +++ b/charts/langsmith/templates/queue/deployment.yaml @@ -64,7 +64,7 @@ spec: envFrom: - configMapRef: name: {{ include "langsmith.fullname" . }}-config - image: "{{ .Values.images.backendImage.repository }}:{{ .Values.images.backendImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "backendImage") | quote }} imagePullPolicy: {{ .Values.images.backendImage.pullPolicy }} {{- with .Values.queue.deployment.startupProbe }} startupProbe: diff --git a/charts/langsmith/templates/quickwit/control-plane-deployment.yaml b/charts/langsmith/templates/quickwit/control-plane-deployment.yaml index a4bf3874..25a65bef 100644 --- a/charts/langsmith/templates/quickwit/control-plane-deployment.yaml +++ b/charts/langsmith/templates/quickwit/control-plane-deployment.yaml @@ -48,7 +48,7 @@ spec: - name: {{ .Values.quickwit.name }} securityContext: {{- toYaml .Values.quickwit.securityContext | nindent 12 }} - image: "{{ .Values.images.quickwitImage.repository }}:{{ .Values.images.quickwitImage.tag }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "quickwitImage") | quote }} imagePullPolicy: {{ .Values.images.quickwitImage.pullPolicy }} args: ["run", "--service", "control_plane"] env: diff --git a/charts/langsmith/templates/quickwit/indexer-stateful-set.yaml b/charts/langsmith/templates/quickwit/indexer-stateful-set.yaml index 082aba17..ca07e130 100644 --- a/charts/langsmith/templates/quickwit/indexer-stateful-set.yaml +++ b/charts/langsmith/templates/quickwit/indexer-stateful-set.yaml @@ -49,7 +49,7 @@ spec: - name: {{ .Values.quickwit.name }} securityContext: {{- toYaml .Values.quickwit.securityContext | nindent 12 }} - image: "{{ .Values.images.quickwitImage.repository }}:{{ .Values.images.quickwitImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "quickwitImage") | quote }} imagePullPolicy: {{ .Values.images.quickwitImage.pullPolicy }} args: ["run", "--service", "indexer"] env: diff --git a/charts/langsmith/templates/quickwit/janitor-deployment.yaml b/charts/langsmith/templates/quickwit/janitor-deployment.yaml index e521f2a5..ab5604b3 100644 --- a/charts/langsmith/templates/quickwit/janitor-deployment.yaml +++ b/charts/langsmith/templates/quickwit/janitor-deployment.yaml @@ -46,7 +46,7 @@ spec: - name: {{ .Values.quickwit.name }} securityContext: {{- toYaml .Values.quickwit.securityContext | nindent 12 }} - image: "{{ .Values.images.quickwitImage.repository }}:{{ .Values.images.quickwitImage.tag }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "quickwitImage") | quote }} imagePullPolicy: {{ .Values.images.quickwitImage.pullPolicy }} args: ["run", "--service", "janitor"] env: diff --git a/charts/langsmith/templates/quickwit/metastore-deployment.yaml b/charts/langsmith/templates/quickwit/metastore-deployment.yaml index 423325c2..408bde84 100644 --- a/charts/langsmith/templates/quickwit/metastore-deployment.yaml +++ b/charts/langsmith/templates/quickwit/metastore-deployment.yaml @@ -46,7 +46,7 @@ spec: - name: {{ .Values.quickwit.name }} securityContext: {{- toYaml .Values.quickwit.securityContext | nindent 12 }} - image: "{{ .Values.images.quickwitImage.repository }}:{{ .Values.images.quickwitImage.tag }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "quickwitImage") | quote }} imagePullPolicy: {{ .Values.images.quickwitImage.pullPolicy }} args: ["run", "--service", "metastore"] env: diff --git a/charts/langsmith/templates/quickwit/searcher-stateful-set.yaml b/charts/langsmith/templates/quickwit/searcher-stateful-set.yaml index 236de21a..8687a72c 100644 --- a/charts/langsmith/templates/quickwit/searcher-stateful-set.yaml +++ b/charts/langsmith/templates/quickwit/searcher-stateful-set.yaml @@ -49,7 +49,7 @@ spec: - name: {{ .Values.quickwit.name }} securityContext: {{- toYaml .Values.quickwit.securityContext | nindent 12 }} - image: "{{ .Values.images.quickwitImage.repository }}:{{ .Values.images.quickwitImage.tag }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "quickwitImage") | quote }} imagePullPolicy: {{ .Values.images.quickwitImage.pullPolicy }} args: ["run", "--service", "searcher"] env: diff --git a/charts/langsmith/templates/quickwit/update-runs-index-job.yaml b/charts/langsmith/templates/quickwit/update-runs-index-job.yaml index ea0eedd3..ffe150b8 100644 --- a/charts/langsmith/templates/quickwit/update-runs-index-job.yaml +++ b/charts/langsmith/templates/quickwit/update-runs-index-job.yaml @@ -24,7 +24,7 @@ spec: restartPolicy: Never initContainers: - name: backend - image: "{{ .Values.images.backendImage.repository }}:{{ .Values.images.backendImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "backendImage") | quote }} command: ["/bin/sh"] args: - "-c" @@ -48,7 +48,7 @@ spec: mountPath: /quickwit containers: - name: {{ .Values.quickwit.name }} - image: "{{ .Values.images.quickwitImage.repository }}:{{ .Values.images.quickwitImage.tag }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "quickwitImage") | quote }} imagePullPolicy: {{ $.Values.images.quickwitImage.pullPolicy }} command: ["/bin/bash"] diff --git a/charts/langsmith/templates/redis/stateful-set.yaml b/charts/langsmith/templates/redis/stateful-set.yaml index 4b5814cb..7dac6ef2 100644 --- a/charts/langsmith/templates/redis/stateful-set.yaml +++ b/charts/langsmith/templates/redis/stateful-set.yaml @@ -54,7 +54,7 @@ spec: {{- toYaml . | nindent 12 }} {{- end }} {{- end }} - image: "{{ .Values.images.redisImage.repository }}:{{ .Values.images.redisImage.tag | default .Chart.AppVersion }}" + image: {{ include "langsmith.image" (dict "Values" .Values "Chart" .Chart "component" "redisImage") | quote }} imagePullPolicy: {{ .Values.images.redisImage.pullPolicy }} ports: - name: redis diff --git a/charts/langsmith/values.yaml b/charts/langsmith/values.yaml index 5250359e..47d47b9f 100644 --- a/charts/langsmith/values.yaml +++ b/charts/langsmith/values.yaml @@ -12,6 +12,7 @@ commonLabels: {} commonEnv: [] images: + defaultRegistry: "" # -- Secrets with credentials to pull images from a private registry. Specified as name: value. imagePullSecrets: [] aceBackendImage: @@ -55,7 +56,7 @@ images: pullPolicy: Always tag: "24.8" quickwitImage: - repository: quickwit/quickwit + repository: "quickwit/quickwit" pullPolicy: IfNotPresent tag: edge From e737e4e579af3d3c67d0200bd1bd7884de92e638 Mon Sep 17 00:00:00 2001 From: romain-priour-lc Date: Wed, 28 May 2025 12:39:01 -0700 Subject: [PATCH 2/4] cleanup --- charts/langsmith/README.md | 2 +- charts/langsmith/templates/_helpers.tpl | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/charts/langsmith/README.md b/charts/langsmith/README.md index c567ed2c..6d346184 100644 --- a/charts/langsmith/README.md +++ b/charts/langsmith/README.md @@ -25,7 +25,7 @@ For information on how to use this chart, up-to-date release notes, and other gu | images.clickhouseImage.pullPolicy | string | `"Always"` | | | images.clickhouseImage.repository | string | `"docker.io/clickhouse/clickhouse-server"` | | | images.clickhouseImage.tag | string | `"24.8"` | | -| images.defaultRegistry | string | "" | If supplied, all images will have this registry name concatenated with a `/` +| images.defaultRegistry | string | "" | If supplied, all children .repository values will be prepended with this registry name + `/` | images.frontendImage.pullPolicy | string | `"IfNotPresent"` | | | images.frontendImage.repository | string | `"docker.io/langchain/langsmith-frontend"` | | | images.frontendImage.tag | string | `"0.10.60"` | | diff --git a/charts/langsmith/templates/_helpers.tpl b/charts/langsmith/templates/_helpers.tpl index 430920a7..739c6e06 100644 --- a/charts/langsmith/templates/_helpers.tpl +++ b/charts/langsmith/templates/_helpers.tpl @@ -611,7 +611,7 @@ checksum/clickhouse: {{ include (print $.Template.BasePath "/clickhouse/secrets. {{- end }} {{/* -Create image reference with registry handling. If defaultRegistry is specified, concatenate with a '/'. +Creates the image reference used for langsmith deployments. If defaultRegistry is specified, concatenate with a '/'. */}} {{- define "langsmith.image" -}} {{- $imageConfig := index .Values.images .component -}} From 713af60150e973be88ca28262a2bc2515c35c220 Mon Sep 17 00:00:00 2001 From: romain-priour-lc Date: Wed, 28 May 2025 15:39:46 -0700 Subject: [PATCH 3/4] review comments + added to all other helm charts --- charts/langgraph-cloud/README.md | 1 + charts/langgraph-cloud/templates/_helpers.tpl | 12 ++++++++++++ .../templates/api-server/deployment.yaml | 2 +- .../templates/postgres/stateful-set.yaml | 2 +- .../langgraph-cloud/templates/queue/deployment.yaml | 2 +- .../langgraph-cloud/templates/redis/deployment.yaml | 2 +- .../templates/studio/deployment.yaml | 2 +- charts/langgraph-cloud/values.yaml | 2 ++ charts/langgraph-dataplane/README.md | 1 + charts/langgraph-dataplane/templates/_helpers.tpl | 13 +++++++++++++ .../templates/listener/deployment.yaml | 2 +- .../templates/operator/deployment.yaml | 2 +- .../templates/redis/stateful-set.yaml | 2 +- charts/langgraph-dataplane/values.yaml | 2 ++ charts/langsmith/README.md | 2 +- charts/langsmith/templates/_helpers.tpl | 8 ++++---- charts/langsmith/values.yaml | 3 ++- charts/open-gpts/README.md | 1 + charts/open-gpts/templates/_helpers.tpl | 12 ++++++++++++ charts/open-gpts/templates/backend/deployment.yaml | 2 +- charts/open-gpts/templates/redis/stateful-set.yaml | 2 +- charts/open-gpts/values.yaml | 2 ++ 22 files changed, 63 insertions(+), 16 deletions(-) diff --git a/charts/langgraph-cloud/README.md b/charts/langgraph-cloud/README.md index cd5e145e..89247579 100644 --- a/charts/langgraph-cloud/README.md +++ b/charts/langgraph-cloud/README.md @@ -205,6 +205,7 @@ the same format as the secret in the corresponding `secrets.yaml` file. Note: AP | images.redisImage.pullPolicy | string | `"IfNotPresent"` | | | images.redisImage.repository | string | `"docker.io/redis"` | | | images.redisImage.tag | string | `"6"` | | +| images.registry | string | "" | If supplied, all children .repository values will be prepended with this registry name + `/` | images.studioImage.pullPolicy | string | `"Always"` | | | images.studioImage.repository | string | `"docker.io/langchain/langgraph-debugger"` | | | images.studioImage.tag | string | `"latest"` | | diff --git a/charts/langgraph-cloud/templates/_helpers.tpl b/charts/langgraph-cloud/templates/_helpers.tpl index 4ae35786..90bd7861 100644 --- a/charts/langgraph-cloud/templates/_helpers.tpl +++ b/charts/langgraph-cloud/templates/_helpers.tpl @@ -143,3 +143,15 @@ the user or some other secret provisioning mechanism {{ default "default" .Values.studio.serviceAccount.name }} {{- end -}} {{- end -}} + +{{/* +Creates the image reference used for LangGraph Cloud deployments. If registry is specified, concatenate it, along with a '/'. +*/}} +{{- define "langGraphCloud.image" -}} +{{- $imageConfig := index .Values.images .component -}} +{{- if .Values.images.registry -}} +{{ .Values.images.registry }}/{{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} +{{- else -}} +{{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} +{{- end -}} +{{- end -}} \ No newline at end of file diff --git a/charts/langgraph-cloud/templates/api-server/deployment.yaml b/charts/langgraph-cloud/templates/api-server/deployment.yaml index bfd64601..de91d238 100644 --- a/charts/langgraph-cloud/templates/api-server/deployment.yaml +++ b/charts/langgraph-cloud/templates/api-server/deployment.yaml @@ -82,7 +82,7 @@ spec: envFrom: {{- toYaml . | nindent 12 }} {{- end }} - image: "{{ .Values.images.apiServerImage.repository }}:{{ .Values.images.apiServerImage.tag | default .Chart.AppVersion }}" + image: {{ include "langGraphCloud.image" (dict "Values" .Values "Chart" .Chart "component" "apiServerImage") | quote }} imagePullPolicy: {{ .Values.images.apiServerImage.pullPolicy }} ports: - name: api-server diff --git a/charts/langgraph-cloud/templates/postgres/stateful-set.yaml b/charts/langgraph-cloud/templates/postgres/stateful-set.yaml index 042d8bc0..f53aa2ce 100644 --- a/charts/langgraph-cloud/templates/postgres/stateful-set.yaml +++ b/charts/langgraph-cloud/templates/postgres/stateful-set.yaml @@ -67,7 +67,7 @@ spec: {{- with .Values.postgres.statefulSet.extraEnv }} {{- toYaml . | nindent 12 }} {{- end }} - image: "{{ .Values.images.postgresImage.repository }}:{{ .Values.images.postgresImage.tag | default .Chart.AppVersion }}" + image: {{ include "langGraphCloud.image" (dict "Values" .Values "Chart" .Chart "component" "postgresImage") | quote }} imagePullPolicy: {{ .Values.images.postgresImage.pullPolicy }} ports: - name: postgres diff --git a/charts/langgraph-cloud/templates/queue/deployment.yaml b/charts/langgraph-cloud/templates/queue/deployment.yaml index 3615101b..914a4156 100644 --- a/charts/langgraph-cloud/templates/queue/deployment.yaml +++ b/charts/langgraph-cloud/templates/queue/deployment.yaml @@ -78,7 +78,7 @@ spec: {{- with .Values.queue.deployment.extraEnv }} {{- toYaml . | nindent 12 }} {{- end }} - image: "{{ .Values.images.apiServerImage.repository }}:{{ .Values.images.apiServerImage.tag | default .Chart.AppVersion }}" + image: {{ include "langGraphCloud.image" (dict "Values" .Values "Chart" .Chart "component" "apiServerImage") | quote }} imagePullPolicy: {{ .Values.images.apiServerImage.pullPolicy }} ports: - name: queue diff --git a/charts/langgraph-cloud/templates/redis/deployment.yaml b/charts/langgraph-cloud/templates/redis/deployment.yaml index 8ef2e5d2..e23a54ca 100644 --- a/charts/langgraph-cloud/templates/redis/deployment.yaml +++ b/charts/langgraph-cloud/templates/redis/deployment.yaml @@ -51,7 +51,7 @@ spec: {{- toYaml . | nindent 12 }} {{- end }} {{- end }} - image: "{{ .Values.images.redisImage.repository }}:{{ .Values.images.redisImage.tag | default .Chart.AppVersion }}" + image: {{ include "langGraphCloud.image" (dict "Values" .Values "Chart" .Chart "component" "redisImage") | quote }} imagePullPolicy: {{ .Values.images.redisImage.pullPolicy }} ports: - name: redis diff --git a/charts/langgraph-cloud/templates/studio/deployment.yaml b/charts/langgraph-cloud/templates/studio/deployment.yaml index 76b8782b..d1238457 100644 --- a/charts/langgraph-cloud/templates/studio/deployment.yaml +++ b/charts/langgraph-cloud/templates/studio/deployment.yaml @@ -49,7 +49,7 @@ spec: {{- with .Values.studio.deployment.extraEnv }} {{- toYaml . | nindent 12 }} {{- end }} - image: "{{ .Values.images.studioImage.repository }}:{{ .Values.images.studioImage.tag | default .Chart.AppVersion }}" + image: {{ include "langGraphCloud.image" (dict "Values" .Values "Chart" .Chart "component" "studioImage") | quote }} imagePullPolicy: {{ .Values.images.studioImage.pullPolicy }} ports: - name: studio diff --git a/charts/langgraph-cloud/values.yaml b/charts/langgraph-cloud/values.yaml index b67c9c65..92475e36 100644 --- a/charts/langgraph-cloud/values.yaml +++ b/charts/langgraph-cloud/values.yaml @@ -10,6 +10,8 @@ commonAnnotations: {} commonLabels: {} images: + # -- If supplied, all children .repository values will be prepended with this registry name + `/` + registry: "" # -- Secrets with credentials to pull images from a private registry. Specified as name: value. imagePullSecrets: [] # This should be the image you have built using the LangGraph Cli. Find more information here: diff --git a/charts/langgraph-dataplane/README.md b/charts/langgraph-dataplane/README.md index fb9e3468..dfc48ef0 100644 --- a/charts/langgraph-dataplane/README.md +++ b/charts/langgraph-dataplane/README.md @@ -26,6 +26,7 @@ Helm chart to deploy a langgraph dataplane on kubernetes. | images.redisImage.pullPolicy | string | `"IfNotPresent"` | | | images.redisImage.repository | string | `"docker.io/redis"` | | | images.redisImage.tag | string | `"7"` | | +| images.registry | string | "" | If supplied, all children .repository values will be prepended with this registry name + `/` | ingress.annotations | object | `{}` | | | ingress.enabled | bool | `true` | | | ingress.hostname | string | `""` | | diff --git a/charts/langgraph-dataplane/templates/_helpers.tpl b/charts/langgraph-dataplane/templates/_helpers.tpl index 80f1834f..c0ec52ca 100644 --- a/charts/langgraph-dataplane/templates/_helpers.tpl +++ b/charts/langgraph-dataplane/templates/_helpers.tpl @@ -174,3 +174,16 @@ Template containing common environment variables that are used by several servic {{ fail (printf "Duplicate keys detected: %v" $duplicates) }} {{- end }} {{- end -}} + + +{{/* +Creates the image reference used for LangGraph DataPlane deployments. If registry is specified, concatenate it, along with a '/'. +*/}} +{{- define "langgraphDataplane.image" -}} +{{- $imageConfig := index .Values.images .component -}} +{{- if .Values.images.registry -}} +{{ .Values.images.registry }}/{{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} +{{- else -}} +{{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} +{{- end -}} +{{- end -}} \ No newline at end of file diff --git a/charts/langgraph-dataplane/templates/listener/deployment.yaml b/charts/langgraph-dataplane/templates/listener/deployment.yaml index aee39548..cfe7b4c5 100644 --- a/charts/langgraph-dataplane/templates/listener/deployment.yaml +++ b/charts/langgraph-dataplane/templates/listener/deployment.yaml @@ -62,7 +62,7 @@ spec: {{- with $envVars }} {{- toYaml . | nindent 12 }} {{- end }} - image: "{{ .Values.images.listenerImage.repository }}:{{ .Values.images.listenerImage.tag | default .Chart.AppVersion }}" + image: {{ include "langgraphDataplane.image" (dict "Values" .Values "Chart" .Chart "component" "listenerImage") | quote }} imagePullPolicy: {{ .Values.images.listenerImage.pullPolicy }} {{- with .Values.listener.deployment.startupProbe }} startupProbe: diff --git a/charts/langgraph-dataplane/templates/operator/deployment.yaml b/charts/langgraph-dataplane/templates/operator/deployment.yaml index 63eada24..78dfff4c 100644 --- a/charts/langgraph-dataplane/templates/operator/deployment.yaml +++ b/charts/langgraph-dataplane/templates/operator/deployment.yaml @@ -49,7 +49,7 @@ spec: args: - --leader-elect - --health-probe-bind-address=:8081 - image: "{{ .Values.images.operatorImage.repository }}:{{ .Values.images.operatorImage.tag | default "latest" }}" + image: {{ include "langgraphDataplane.image" (dict "Values" .Values "Chart" .Chart "component" "operatorImage") | quote }} imagePullPolicy: {{ .Values.images.operatorImage.pullPolicy }} name: {{ .Values.operator.name }} {{- with .Values.operator.deployment.securityContext }} diff --git a/charts/langgraph-dataplane/templates/redis/stateful-set.yaml b/charts/langgraph-dataplane/templates/redis/stateful-set.yaml index 65c46785..56756ae0 100644 --- a/charts/langgraph-dataplane/templates/redis/stateful-set.yaml +++ b/charts/langgraph-dataplane/templates/redis/stateful-set.yaml @@ -54,7 +54,7 @@ spec: {{- toYaml . | nindent 12 }} {{- end }} {{- end }} - image: "{{ .Values.images.redisImage.repository }}:{{ .Values.images.redisImage.tag | default .Chart.AppVersion }}" + image: {{ include "langgraphDataplane.image" (dict "Values" .Values "Chart" .Chart "component" "redisImage") | quote }} imagePullPolicy: {{ .Values.images.redisImage.pullPolicy }} ports: - name: redis diff --git a/charts/langgraph-dataplane/values.yaml b/charts/langgraph-dataplane/values.yaml index c5dc40c2..99546e10 100644 --- a/charts/langgraph-dataplane/values.yaml +++ b/charts/langgraph-dataplane/values.yaml @@ -12,6 +12,8 @@ commonLabels: {} commonEnv: [] images: + # -- If supplied, all children .repository values will be prepended with this registry name + `/` + registry: "" # -- Secrets with credentials to pull images from a private registry. Specified as name: value. imagePullSecrets: [] listenerImage: diff --git a/charts/langsmith/README.md b/charts/langsmith/README.md index 6d346184..2093b03b 100644 --- a/charts/langsmith/README.md +++ b/charts/langsmith/README.md @@ -25,7 +25,6 @@ For information on how to use this chart, up-to-date release notes, and other gu | images.clickhouseImage.pullPolicy | string | `"Always"` | | | images.clickhouseImage.repository | string | `"docker.io/clickhouse/clickhouse-server"` | | | images.clickhouseImage.tag | string | `"24.8"` | | -| images.defaultRegistry | string | "" | If supplied, all children .repository values will be prepended with this registry name + `/` | images.frontendImage.pullPolicy | string | `"IfNotPresent"` | | | images.frontendImage.repository | string | `"docker.io/langchain/langsmith-frontend"` | | | images.frontendImage.tag | string | `"0.10.60"` | | @@ -51,6 +50,7 @@ For information on how to use this chart, up-to-date release notes, and other gu | images.redisImage.pullPolicy | string | `"IfNotPresent"` | | | images.redisImage.repository | string | `"docker.io/redis"` | | | images.redisImage.tag | string | `"7"` | | +| images.registry | string | "" | If supplied, all children .repository values will be prepended with this registry name + `/` | ingress.annotations | object | `{}` | | | ingress.enabled | bool | `false` | Set to true if langgraph platform enabled. | | ingress.hostname | string | `""` | | diff --git a/charts/langsmith/templates/_helpers.tpl b/charts/langsmith/templates/_helpers.tpl index 739c6e06..9b1c62b2 100644 --- a/charts/langsmith/templates/_helpers.tpl +++ b/charts/langsmith/templates/_helpers.tpl @@ -611,13 +611,13 @@ checksum/clickhouse: {{ include (print $.Template.BasePath "/clickhouse/secrets. {{- end }} {{/* -Creates the image reference used for langsmith deployments. If defaultRegistry is specified, concatenate with a '/'. +Creates the image reference used for Langsmith deployments. If registry is specified, concatenate it, along with a '/'. */}} {{- define "langsmith.image" -}} {{- $imageConfig := index .Values.images .component -}} -{{- if .Values.images.defaultRegistry -}} -{{ .Values.images.defaultRegistry }}/{{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} +{{- if .Values.images.registry -}} +{{ .Values.images.registry }}/{{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} {{- else -}} {{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} {{- end -}} -{{- end -}} \ No newline at end of file +{{- end -}} diff --git a/charts/langsmith/values.yaml b/charts/langsmith/values.yaml index 47d47b9f..407f1453 100644 --- a/charts/langsmith/values.yaml +++ b/charts/langsmith/values.yaml @@ -12,7 +12,8 @@ commonLabels: {} commonEnv: [] images: - defaultRegistry: "" + # -- If supplied, all children .repository values will be prepended with this registry name + `/` + registry: "" # -- Secrets with credentials to pull images from a private registry. Specified as name: value. imagePullSecrets: [] aceBackendImage: diff --git a/charts/open-gpts/README.md b/charts/open-gpts/README.md index c07806ce..1ba4c0bc 100644 --- a/charts/open-gpts/README.md +++ b/charts/open-gpts/README.md @@ -168,6 +168,7 @@ the same format as the secret in the corresponding `secrets.yaml` file. | images.redisImage.pullPolicy | string | `"IfNotPresent"` | | | images.redisImage.repository | string | `"docker.io/redis/redis-stack-server"` | | | images.redisImage.tag | string | `"latest"` | | +| images.registry | string | "" | If supplied, all children .repository values will be prepended with this registry name + `/` | ingress.annotations | object | `{}` | | | ingress.enabled | bool | `false` | | | ingress.hostname | string | `""` | | diff --git a/charts/open-gpts/templates/_helpers.tpl b/charts/open-gpts/templates/_helpers.tpl index b14f76f8..e45f38b7 100644 --- a/charts/open-gpts/templates/_helpers.tpl +++ b/charts/open-gpts/templates/_helpers.tpl @@ -107,3 +107,15 @@ the user or some other secret provisioning mechanism {{ default "default" .Values.redis.serviceAccount.name }} {{- end -}} {{- end -}} + +{{/* +Creates the image reference used for openGPTs deployments. If registry is specified, concatenate it, along with a '/'. +*/}} +{{- define "openGPTs.image" -}} +{{- $imageConfig := index .Values.images .component -}} +{{- if .Values.images.registry -}} +{{ .Values.images.registry }}/{{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} +{{- else -}} +{{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} +{{- end -}} +{{- end -}} diff --git a/charts/open-gpts/templates/backend/deployment.yaml b/charts/open-gpts/templates/backend/deployment.yaml index 5a23bc9c..852931d1 100644 --- a/charts/open-gpts/templates/backend/deployment.yaml +++ b/charts/open-gpts/templates/backend/deployment.yaml @@ -110,7 +110,7 @@ spec: {{- with .Values.backend.deployment.extraEnv }} {{- toYaml . | nindent 12 }} {{- end }} - image: "{{ .Values.images.backendImage.repository }}:{{ .Values.images.backendImage.tag | default .Chart.AppVersion }}" + image: {{ include "openGPTs.image" (dict "Values" .Values "Chart" .Chart "component" "backendImage") | quote }} imagePullPolicy: {{ .Values.images.backendImage.pullPolicy }} ports: - name: backend diff --git a/charts/open-gpts/templates/redis/stateful-set.yaml b/charts/open-gpts/templates/redis/stateful-set.yaml index 2d1f01e8..47dbb890 100644 --- a/charts/open-gpts/templates/redis/stateful-set.yaml +++ b/charts/open-gpts/templates/redis/stateful-set.yaml @@ -46,7 +46,7 @@ spec: env: {{- toYaml . | nindent 12 }} {{- end }} - image: "{{ .Values.images.redisImage.repository }}:{{ .Values.images.redisImage.tag | default .Chart.AppVersion }}" + image: {{ include "openGPTs.image" (dict "Values" .Values "Chart" .Chart "component" "redisImage") | quote }} imagePullPolicy: {{ .Values.images.redisImage.pullPolicy }} ports: - name: redis diff --git a/charts/open-gpts/values.yaml b/charts/open-gpts/values.yaml index 17cb5ea5..cb4bef66 100644 --- a/charts/open-gpts/values.yaml +++ b/charts/open-gpts/values.yaml @@ -10,6 +10,8 @@ commonAnnotations: {} commonLabels: {} images: + # -- If supplied, all children .repository values will be prepended with this registry name + `/` + registry: "" # -- Secrets with credentials to pull images from a private registry. Specified as name: value. imagePullSecrets: [] backendImage: From 440b8797313e33b27ec781746b9dcc7cf308b2cb Mon Sep 17 00:00:00 2001 From: romain-priour-lc Date: Thu, 29 May 2025 15:24:16 -0700 Subject: [PATCH 4/4] add newlines --- charts/langgraph-cloud/templates/_helpers.tpl | 2 +- charts/langgraph-dataplane/templates/_helpers.tpl | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/charts/langgraph-cloud/templates/_helpers.tpl b/charts/langgraph-cloud/templates/_helpers.tpl index 90bd7861..02d2577d 100644 --- a/charts/langgraph-cloud/templates/_helpers.tpl +++ b/charts/langgraph-cloud/templates/_helpers.tpl @@ -154,4 +154,4 @@ Creates the image reference used for LangGraph Cloud deployments. If registry is {{- else -}} {{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} {{- end -}} -{{- end -}} \ No newline at end of file +{{- end -}} diff --git a/charts/langgraph-dataplane/templates/_helpers.tpl b/charts/langgraph-dataplane/templates/_helpers.tpl index c0ec52ca..04ff2486 100644 --- a/charts/langgraph-dataplane/templates/_helpers.tpl +++ b/charts/langgraph-dataplane/templates/_helpers.tpl @@ -186,4 +186,4 @@ Creates the image reference used for LangGraph DataPlane deployments. If registr {{- else -}} {{ $imageConfig.repository }}:{{ $imageConfig.tag | default .Chart.AppVersion }} {{- end -}} -{{- end -}} \ No newline at end of file +{{- end -}}