Skip to content

Commit 1f66cfd

Browse files
authored
refactor: rename llmProxy to aiProxy
across helm chart (#794) * refactor: rename llmProxy to aiProxy across helm chart Complete rename of llmProxy/llmproxy to aiProxy/aiproxy for better alignment with product naming conventions. Changes: - Renamed chart/templates/llmproxy/ directory to aiproxy/ - Updated 7 helper functions in _helpers.tpl - Renamed llmProxy section to aiProxy in values.yaml - Updated all 6 template files (deployment, service, configmap, etc.) - Updated KOTS manifests (config, helm, app) - Updated router, ai-api, and workspace-api configmaps - Updated README.md parameter documentation - Fixed all references including comments and descriptions Breaking changes: - Helm value section renamed: llmProxy -> aiProxy - Database name parameter: llmProxyDatabaseName -> aiProxyDatabaseName - Router env vars: enablellmProxyEndpoint -> enableAiProxyEndpoint - Component labels: llmproxy -> aiproxy Validation: - helm lint passes without errors - helm template renders successfully - No remaining llmProxy references found * fix(aiproxy): correct component label case in pod affinity rules Change component labels from 'aiProxy' to 'aiproxy' (lowercase) to match the app.kubernetes.io/component label used throughout the deployment template. This ensures pod affinity/anti-affinity rules correctly match the aiproxy pods. * fix(workspace-api): update template reference from llmProxy to aiProxy Fix missed template rename in workspace-api configmap. The WORKSPACE_LITELLM_BASE_URL was still referencing the old 'carto.llmProxy.fullname' template which no longer exists. Updated to use 'carto.aiProxy.fullname' to match the rename done in commit af50b3d. Error: template: no template "carto.llmProxy.fullname" associated with template "gotpl" * fix(kots): use lowercase 'aiproxy' for database name default Change aiProxyDatabaseName default from 'aiProxy' (camelCase) to 'aiproxy' (lowercase) to match: - Helm chart default (values.yaml) - Component labels - Deployment/service names This ensures consistency across all aiproxy resources. * fix(docs): update aiProxy parameter descriptions to use correct component name Updated all @param annotations in values.yaml for the aiProxy section to consistently refer to 'aiProxy' instead of incorrectly referencing 'ai-api'. This ensures the auto-generated README.md has accurate documentation following the llmProxy to aiProxy rename. Changes: - Updated 48 parameter descriptions in aiProxy section - Fixed probe descriptions (liveness, readiness, startup) - Fixed autoscaling, security context, and pod management descriptions - Fixed service parameter descriptions - Corrected section header from "ai-api Service Parameters" to "aiProxy Service Parameters" - Fixed existingSecret description to correctly say "Secret" not "ConfigMap" * feat(kots): add hidden enableAiProxyEndpoint parameter Added enableAiProxyEndpoint as a hidden boolean parameter in kots-config.yaml. This parameter: - Is hidden from the UI (hidden: true) - Only active when aiFeaturesEnabled is "1" - Defaults to "1" (enabled) - Can be used in Helm templates via ConfigOption This allows controlling the aiProxy endpoint feature without exposing it in the KOTS admin UI. * Remove AI Proxy setting from kots
1 parent dff8242 commit 1f66cfd

File tree

16 files changed

+385
-386
lines changed

16 files changed

+385
-386
lines changed

chart/README.md

Lines changed: 97 additions & 97 deletions
Large diffs are not rendered by default.

chart/templates/_helpers.tpl

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -897,7 +897,7 @@ Return the proper Carto tenant-requirements-checker image name
897897
Return the proper Docker Image Registry Secret Names
898898
*/}}
899899
{{- define "carto.imagePullSecrets" -}}
900-
{{- include "common.images.renderPullSecrets" (dict "images" (list .Values.accountsWww.image .Values.importApi.image .Values.importWorker.image .Values.ldsApi.image .Values.mapsApi.image .Values.router.image .Values.httpCache.image .Values.cdnInvalidatorSub.image .Values.workspaceApi.image .Values.workspaceSubscriber.image .Values.workspaceWww.image .Values.workspaceMigrations.image .Values.internalRedis.image .Values.aiApi.image .Values.llmProxy.image) "context" $) -}}
900+
{{- include "common.images.renderPullSecrets" (dict "images" (list .Values.accountsWww.image .Values.importApi.image .Values.importWorker.image .Values.ldsApi.image .Values.mapsApi.image .Values.router.image .Values.httpCache.image .Values.cdnInvalidatorSub.image .Values.workspaceApi.image .Values.workspaceSubscriber.image .Values.workspaceWww.image .Values.workspaceMigrations.image .Values.internalRedis.image .Values.aiApi.image .Values.aiProxy.image) "context" $) -}}
901901
{{- end -}}
902902

903903
{{/*
@@ -1394,45 +1394,45 @@ Create aiApi Node options
13941394
{{- end -}}
13951395

13961396
{{/*
1397-
Create a default fully qualified llmProxy name.
1397+
Create a default fully qualified aiProxy name.
13981398
*/}}
1399-
{{- define "carto.llmProxy.fullname" -}}
1400-
{{- printf "%s-llmproxy" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" -}}
1399+
{{- define "carto.aiProxy.fullname" -}}
1400+
{{- printf "%s-aiproxy" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" -}}
14011401
{{- end -}}
14021402

1403-
{{/*
1404-
Create carto Image full name for llmProxy
1403+
{{/*
1404+
Create carto Image full name for aiProxy
14051405
*/}}
1406-
{{- define "carto.llmProxy.image" -}}
1407-
{{- include "carto.images.image" (dict "imageRoot" .Values.llmProxy.image "global" .Values.global "Chart" .Chart) -}}
1406+
{{- define "carto.aiProxy.image" -}}
1407+
{{- include "carto.images.image" (dict "imageRoot" .Values.aiProxy.image "global" .Values.global "Chart" .Chart) -}}
14081408
{{- end -}}
14091409

14101410
{{/*
1411-
Create the name of the llmProxy configmap
1411+
Create the name of the aiProxy configmap
14121412
*/}}
1413-
{{- define "carto.llmProxy.configmapName" -}}
1414-
{{- if .Values.llmProxy.existingConfigMap -}}
1415-
{{- .Values.llmProxy.existingConfigMap -}}
1413+
{{- define "carto.aiProxy.configmapName" -}}
1414+
{{- if .Values.aiProxy.existingConfigMap -}}
1415+
{{- .Values.aiProxy.existingConfigMap -}}
14161416
{{- else -}}
1417-
{{- include "carto.llmProxy.fullname" . -}}
1417+
{{- include "carto.aiProxy.fullname" . -}}
14181418
{{- end -}}
14191419
{{- end -}}
14201420

14211421
{{/*
1422-
Create the name of the llmProxy secret
1422+
Create the name of the aiProxy secret
14231423
*/}}
1424-
{{- define "carto.llmProxy.secretName" -}}
1425-
{{- if .Values.llmProxy.existingSecret -}}
1426-
{{- .Values.llmProxy.existingSecret -}}
1424+
{{- define "carto.aiProxy.secretName" -}}
1425+
{{- if .Values.aiProxy.existingSecret -}}
1426+
{{- .Values.aiProxy.existingSecret -}}
14271427
{{- else -}}
1428-
{{- include "carto.llmProxy.fullname" . -}}
1428+
{{- include "carto.aiProxy.fullname" . -}}
14291429
{{- end -}}
14301430
{{- end -}}
14311431

14321432
{{/*
1433-
Return the llmProxy database ssl mode
1433+
Return the aiProxy database ssl mode
14341434
*/}}
1435-
{{- define "carto.llmProxy.databaseSslMode" -}}
1435+
{{- define "carto.aiProxy.databaseSslMode" -}}
14361436
{{- if .Values.externalPostgresql.sslEnabled -}}
14371437
require
14381438
{{- else -}}
@@ -1441,15 +1441,15 @@ disable
14411441
{{- end -}}
14421442

14431443
{{/*
1444-
Return the llmProxy master key checksum
1444+
Return the aiProxy master key checksum
14451445
*/}}
1446-
{{- define "carto.llmProxy.masterKeyChecksum" -}}
1446+
{{- define "carto.aiProxy.masterKeyChecksum" -}}
14471447
{{- .Values.cartoSecrets.litellmMasterKey.value | sha256sum -}}
14481448
{{- end -}}
14491449

14501450
{{/*
1451-
Return the llmProxy salt key checksum
1451+
Return the aiProxy salt key checksum
14521452
*/}}
1453-
{{- define "carto.llmProxy.saltKeyChecksum" -}}
1453+
{{- define "carto.aiProxy.saltKeyChecksum" -}}
14541454
{{- .Values.cartoSecrets.litellmSaltKey.value | sha256sum -}}
14551455
{{- end -}}

chart/templates/ai-api/configmap.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ metadata:
1414
{{- end }}
1515
data:
1616
AI_ERROR_RESPONSE_STACK_TRACE: {{ .Values.cartoConfigValues.enableErrorResponseStackTrace | quote }}
17-
# AI_OPENAI_ENDPOINT points to llmProxy proxy service, not directly to OpenAI
18-
# llmProxy acts as a unified gateway that can route to various AI providers
19-
AI_OPENAI_ENDPOINT: "http://{{ include "carto.llmProxy.fullname" . }}.{{ .Release.Namespace }}.svc.{{ .Values.clusterDomain }}/v1"
17+
# AI_OPENAI_ENDPOINT points to aiProxy proxy service, not directly to OpenAI
18+
# aiProxy acts as a unified gateway that can route to various AI providers
19+
AI_OPENAI_ENDPOINT: "http://{{ include "carto.aiProxy.fullname" . }}.{{ .Release.Namespace }}.svc.{{ .Values.clusterDomain }}/v1"
2020
AI_SQL_API_URL: "http://{{ include "carto.mapsApi.fullname" . }}.{{ .Release.Namespace }}.svc.{{ .Values.clusterDomain }}"
2121
AI_LDS_API_URL: "http://{{ include "carto.ldsApi.fullname" . }}.{{ .Release.Namespace }}.svc.{{ .Values.clusterDomain }}"
2222
AI_TENANT_ID: {{ .Values.cartoConfigValues.selfHostedTenantId | quote }}
@@ -60,7 +60,7 @@ data:
6060
{{- if and .Values.externalRedis.tlsEnabled .Values.externalRedis.tlsCA }}
6161
REDIS_TLS_CA: {{ .Values.externalRedis.tlsCA | quote }}
6262
{{- end }}
63-
WORKSPACE_LITELLM_BASE_URL: "http://{{ include "carto.llmProxy.fullname" . }}.{{ .Release.Namespace }}.svc.{{ .Values.clusterDomain }}"
63+
WORKSPACE_LITELLM_BASE_URL: "http://{{ include "carto.aiProxy.fullname" . }}.{{ .Release.Namespace }}.svc.{{ .Values.clusterDomain }}"
6464
WORKSPACE_POSTGRES_DB: {{ include "carto.postgresql.databaseName" . | quote }}
6565
WORKSPACE_POSTGRES_HOST: {{ include "carto.postgresql.host" . | quote }}
6666
WORKSPACE_POSTGRES_PORT: {{ include "carto.postgresql.port" . | quote }}
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22
apiVersion: v1
33
kind: ConfigMap
44
metadata:
5-
name: {{ template "carto.llmProxy.configmapName" . }}
5+
name: {{ template "carto.aiProxy.configmapName" . }}
66
namespace: {{ .Release.Namespace | quote }}
77
labels: {{- include "common.labels.standard" . | nindent 4 }}
8-
app.kubernetes.io/component: llmproxy
8+
app.kubernetes.io/component: aiproxy
99
{{- if .Values.commonLabels }}
1010
{{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }}
1111
{{- end }}
@@ -19,9 +19,9 @@ data:
1919
AI_API_URL: "http://{{ include "carto.aiApi.fullname" . }}.{{ .Release.Namespace }}.svc.{{ .Values.clusterDomain }}"
2020
DATABASE_HOST: {{ include "carto.postgresql.host" . | quote }}
2121
DATABASE_USERNAME: {{ include "carto.postgresql.user" . | quote }}
22-
DATABASE_NAME: {{ .Values.externalPostgresql.llmProxyDatabaseName | quote }}
22+
DATABASE_NAME: {{ .Values.externalPostgresql.aiProxyDatabaseName | quote }}
2323
DATABASE_PORT: {{ include "carto.postgresql.port" . | quote }}
24-
DATABASE_SSL_MODE: {{ include "carto.llmProxy.databaseSslMode" . | quote }}
24+
DATABASE_SSL_MODE: {{ include "carto.aiProxy.databaseSslMode" . | quote }}
2525
DATABASE_SSL_CA_PATH: {{ include "carto.postgresql.configMapMountAbsolutePath" . | quote }}
2626
{{- if .Values.externalProxy.enabled }}
2727
HTTP_PROXY: {{ include "carto.proxy.computedConnectionString" . | quote }}
@@ -49,7 +49,7 @@ data:
4949
REDIS_PORT: {{ include "carto.redis.port" . | quote }}
5050
SERVER_ROOT_PATH: "/litellm"
5151
{{- if and .Values.externalProxy.enabled (or .Values.externalProxy.sslCA .Values.externalProxy.sslCAConfigmap.name) }}
52-
# llmproxy python httpx requirement
52+
# aiproxy python httpx requirement
5353
SSL_CERT_FILE: {{ include "carto.proxy.configMapMountAbsolutePath" . | quote }}
5454
{{- end }}
5555
XDG_CACHE_HOME: "/app/.cache/prisma"

0 commit comments

Comments
 (0)