From 80b3974f8cb941e9567e15aaddd80e390363bb08 Mon Sep 17 00:00:00 2001 From: Jaume Alavedra Date: Sun, 7 Jun 2026 19:49:18 +0000 Subject: [PATCH] fix: restore laminar chart templates and api tracing Upstream removed laminar in 6a96324c, but our deployment still routes laminar-centaur.fort.dev through cloudflared and the api/slackbot/chatbot pods already have LMNR_* env vars baked in. Without the templates the laminar services never get created, so the public route hits a dead backend and the apps log laminar export failures. Restore the deleted contrib/chart/templates/laminar.yaml (6 services, 3 Deployments, 3 StatefulSets reusing the existing PVCs) and the full values block. Also keep services/api/api/laminar_tracing.py so the runtime_control imports resolve. Co-Authored-By: Claude Opus 4.7 (1M context) --- contrib/chart/templates/_helpers.tpl | 10 + contrib/chart/templates/laminar.yaml | 506 +++++++++++++++++++++++++++ contrib/chart/values.dev.yaml | 16 +- contrib/chart/values.yaml | 79 +++++ services/api/api/laminar_tracing.py | 24 ++ 5 files changed, 634 insertions(+), 1 deletion(-) create mode 100644 contrib/chart/templates/laminar.yaml create mode 100644 services/api/api/laminar_tracing.py diff --git a/contrib/chart/templates/_helpers.tpl b/contrib/chart/templates/_helpers.tpl index 8a4302263..be4c0ae48 100644 --- a/contrib/chart/templates/_helpers.tpl +++ b/contrib/chart/templates/_helpers.tpl @@ -140,3 +140,13 @@ registered refresh_token OAuthTokenSecrets by the API server at startup. {{- define "centaur.tokenBrokerUrl" -}} {{- printf "http://%s:%v" (include "centaur.tokenBrokerHost" .) .Values.tokenBroker.service.httpPort -}} {{- end -}} + +{{- define "centaur.laminarNoProxyHosts" -}} +{{- if .Values.laminar.enabled -}} +{{- printf ",%s,%s,%s,%s,%s,%s" (include "centaur.componentName" (dict "root" . "component" "laminar-app-server")) (include "centaur.componentName" (dict "root" . "component" "laminar-frontend")) (include "centaur.componentName" (dict "root" . "component" "laminar-postgres")) (include "centaur.componentName" (dict "root" . "component" "laminar-clickhouse")) (include "centaur.componentName" (dict "root" . "component" "laminar-query-engine")) (include "centaur.componentName" (dict "root" . "component" "laminar-quickwit")) -}} +{{- end -}} +{{- end -}} + +{{- define "centaur.laminarBaseUrl" -}} +{{- printf "http://%s" (include "centaur.componentName" (dict "root" . "component" "laminar-app-server")) -}} +{{- end -}} diff --git a/contrib/chart/templates/laminar.yaml b/contrib/chart/templates/laminar.yaml new file mode 100644 index 000000000..4801f57c7 --- /dev/null +++ b/contrib/chart/templates/laminar.yaml @@ -0,0 +1,506 @@ +{{- if .Values.laminar.enabled }} +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-clickhouse-config") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-clickhouse") | nindent 4 }} +data: + lmnr.xml: | + + + + 1 + 1 + + + +--- +apiVersion: v1 +kind: Service +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-postgres") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-postgres") | nindent 4 }} +spec: + selector: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-postgres") | nindent 4 }} + ports: + - name: postgres + port: 5432 + targetPort: 5432 +--- +apiVersion: v1 +kind: Service +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-clickhouse") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-clickhouse") | nindent 4 }} +spec: + selector: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-clickhouse") | nindent 4 }} + ports: + - name: http + port: {{ .Values.laminar.clickhouse.service.httpPort }} + targetPort: {{ .Values.laminar.clickhouse.service.httpPort }} + - name: native + port: {{ .Values.laminar.clickhouse.service.nativePort }} + targetPort: {{ .Values.laminar.clickhouse.service.nativePort }} +--- +apiVersion: v1 +kind: Service +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-quickwit") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-quickwit") | nindent 4 }} +spec: + selector: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-quickwit") | nindent 4 }} + ports: + - name: http + port: {{ .Values.laminar.quickwit.service.httpPort }} + targetPort: {{ .Values.laminar.quickwit.service.httpPort }} + - name: grpc + port: {{ .Values.laminar.quickwit.service.grpcPort }} + targetPort: {{ .Values.laminar.quickwit.service.grpcPort }} +--- +apiVersion: v1 +kind: Service +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-query-engine") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-query-engine") | nindent 4 }} +spec: + selector: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-query-engine") | nindent 4 }} + ports: + - name: http + port: {{ .Values.laminar.queryEngine.service.port }} + targetPort: {{ .Values.laminar.queryEngine.service.port }} +--- +apiVersion: v1 +kind: Service +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-app-server") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-app-server") | nindent 4 }} +spec: + selector: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-app-server") | nindent 4 }} + ports: + - name: http + port: {{ .Values.laminar.appServer.service.httpPort }} + targetPort: {{ .Values.laminar.appServer.service.httpPort }} + - name: grpc + port: {{ .Values.laminar.appServer.service.grpcPort }} + targetPort: {{ .Values.laminar.appServer.service.grpcPort }} + - name: realtime + port: {{ .Values.laminar.appServer.service.realtimePort }} + targetPort: {{ .Values.laminar.appServer.service.realtimePort }} +--- +apiVersion: v1 +kind: Service +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-frontend") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-frontend") | nindent 4 }} +spec: + selector: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-frontend") | nindent 4 }} + ports: + - name: http + port: {{ .Values.laminar.frontend.service.port }} + targetPort: {{ .Values.laminar.frontend.service.port }} +--- +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-postgres") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-postgres") | nindent 4 }} +spec: + serviceName: {{ include "centaur.componentName" (dict "root" . "component" "laminar-postgres") }} + replicas: 1 + selector: + matchLabels: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-postgres") | nindent 6 }} + template: + metadata: + labels: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-postgres") | nindent 8 }} + spec: + automountServiceAccountToken: false + containers: + - name: postgres + image: {{ printf "%s:%s" .Values.laminar.postgres.image.repository .Values.laminar.postgres.image.tag | quote }} + imagePullPolicy: {{ .Values.laminar.imagePullPolicy }} + env: + - name: POSTGRES_DB + value: {{ .Values.laminar.postgres.auth.database | quote }} + - name: POSTGRES_USER + value: {{ .Values.laminar.postgres.auth.username | quote }} + - name: POSTGRES_PASSWORD + value: {{ .Values.laminar.postgres.auth.password | quote }} + ports: + - name: postgres + containerPort: 5432 + readinessProbe: + tcpSocket: + port: 5432 + volumeMounts: + - name: data + mountPath: /var/lib/postgresql/data + resources: +{{ toYaml .Values.laminar.postgres.resources | nindent 12 }} + {{- if .Values.laminar.postgres.persistence.enabled }} + volumeClaimTemplates: + - metadata: + name: data + spec: + accessModes: ["ReadWriteOnce"] + {{- with .Values.laminar.postgres.persistence.storageClassName }} + storageClassName: {{ . | quote }} + {{- end }} + resources: + requests: + storage: {{ .Values.laminar.postgres.persistence.size }} + {{- else }} + volumeClaimTemplates: [] + {{- end }} +--- +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-clickhouse") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-clickhouse") | nindent 4 }} +spec: + serviceName: {{ include "centaur.componentName" (dict "root" . "component" "laminar-clickhouse") }} + replicas: 1 + selector: + matchLabels: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-clickhouse") | nindent 6 }} + template: + metadata: + labels: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-clickhouse") | nindent 8 }} + spec: + automountServiceAccountToken: false + containers: + - name: clickhouse + image: {{ printf "%s:%s" .Values.laminar.clickhouse.image.repository .Values.laminar.clickhouse.image.tag | quote }} + imagePullPolicy: {{ .Values.laminar.imagePullPolicy }} + env: + - name: CLICKHOUSE_USER + value: {{ .Values.laminar.clickhouse.auth.user | quote }} + - name: CLICKHOUSE_PASSWORD + value: {{ .Values.laminar.clickhouse.auth.password | quote }} + ports: + - name: http + containerPort: {{ .Values.laminar.clickhouse.service.httpPort }} + - name: native + containerPort: {{ .Values.laminar.clickhouse.service.nativePort }} + readinessProbe: + tcpSocket: + port: {{ .Values.laminar.clickhouse.service.httpPort }} + volumeMounts: + - name: data + mountPath: /var/lib/clickhouse + - name: logs + mountPath: /var/log/clickhouse-server + - name: config + mountPath: /etc/clickhouse-server/users.d/lmnr.xml + subPath: lmnr.xml + resources: +{{ toYaml .Values.laminar.clickhouse.resources | nindent 12 }} + volumes: + - name: config + configMap: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-clickhouse-config") }} + - name: logs + emptyDir: {} + {{- if .Values.laminar.clickhouse.persistence.enabled }} + volumeClaimTemplates: + - metadata: + name: data + spec: + accessModes: ["ReadWriteOnce"] + {{- with .Values.laminar.clickhouse.persistence.storageClassName }} + storageClassName: {{ . | quote }} + {{- end }} + resources: + requests: + storage: {{ .Values.laminar.clickhouse.persistence.size }} + {{- else }} + volumeClaimTemplates: [] + {{- end }} +--- +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-quickwit") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-quickwit") | nindent 4 }} +spec: + serviceName: {{ include "centaur.componentName" (dict "root" . "component" "laminar-quickwit") }} + replicas: 1 + selector: + matchLabels: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-quickwit") | nindent 6 }} + template: + metadata: + labels: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-quickwit") | nindent 8 }} + spec: + automountServiceAccountToken: false + containers: + - name: quickwit + image: {{ printf "%s:%s" .Values.laminar.quickwit.image.repository .Values.laminar.quickwit.image.tag | quote }} + imagePullPolicy: {{ .Values.laminar.imagePullPolicy }} + command: ["quickwit"] + args: ["run"] + env: + - name: QW_DATA_DIR + value: /quickwit/qwdata + ports: + - name: http + containerPort: {{ .Values.laminar.quickwit.service.httpPort }} + - name: grpc + containerPort: {{ .Values.laminar.quickwit.service.grpcPort }} + readinessProbe: + httpGet: + path: /health/livez + port: {{ .Values.laminar.quickwit.service.httpPort }} + failureThreshold: 30 + volumeMounts: + - name: data + mountPath: /quickwit/qwdata + resources: +{{ toYaml .Values.laminar.quickwit.resources | nindent 12 }} + {{- if .Values.laminar.quickwit.persistence.enabled }} + volumeClaimTemplates: + - metadata: + name: data + spec: + accessModes: ["ReadWriteOnce"] + {{- with .Values.laminar.quickwit.persistence.storageClassName }} + storageClassName: {{ . | quote }} + {{- end }} + resources: + requests: + storage: {{ .Values.laminar.quickwit.persistence.size }} + {{- else }} + volumeClaimTemplates: [] + {{- end }} +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-query-engine") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-query-engine") | nindent 4 }} +spec: + replicas: 1 + selector: + matchLabels: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-query-engine") | nindent 6 }} + template: + metadata: + labels: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-query-engine") | nindent 8 }} + spec: + automountServiceAccountToken: false + containers: + - name: query-engine + image: {{ printf "%s:%s" .Values.laminar.queryEngine.image.repository .Values.laminar.queryEngine.image.tag | quote }} + imagePullPolicy: {{ .Values.laminar.imagePullPolicy }} + env: + - name: PORT + value: {{ .Values.laminar.queryEngine.service.port | quote }} + ports: + - name: http + containerPort: {{ .Values.laminar.queryEngine.service.port }} + readinessProbe: + tcpSocket: + port: {{ .Values.laminar.queryEngine.service.port }} + resources: +{{ toYaml .Values.laminar.queryEngine.resources | nindent 12 }} +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-app-server") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-app-server") | nindent 4 }} +spec: + replicas: 1 + selector: + matchLabels: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-app-server") | nindent 6 }} + template: + metadata: + labels: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-app-server") | nindent 8 }} + spec: + automountServiceAccountToken: false + initContainers: + - name: wait-for-laminar-dependencies + image: {{ printf "%s:%s" .Values.laminar.waitImage.repository .Values.laminar.waitImage.tag | quote }} + imagePullPolicy: {{ .Values.laminar.waitImage.pullPolicy }} + command: + - /bin/sh + - -ec + - | + for target in \ + {{ include "centaur.componentName" (dict "root" . "component" "laminar-postgres") }}:5432 \ + {{ include "centaur.componentName" (dict "root" . "component" "laminar-clickhouse") }}:{{ .Values.laminar.clickhouse.service.httpPort }} \ + {{ include "centaur.componentName" (dict "root" . "component" "laminar-quickwit") }}:{{ .Values.laminar.quickwit.service.httpPort }} \ + {{ include "centaur.componentName" (dict "root" . "component" "laminar-query-engine") }}:{{ .Values.laminar.queryEngine.service.port }} + do + host="${target%:*}" + port="${target##*:}" + until nc -z "$host" "$port"; do + sleep 2 + done + done + containers: + - name: app-server + image: {{ printf "%s:%s" .Values.laminar.appServer.image.repository .Values.laminar.appServer.image.tag | quote }} + imagePullPolicy: {{ .Values.laminar.imagePullPolicy }} + env: + - name: PORT + value: {{ .Values.laminar.appServer.service.httpPort | quote }} + - name: GRPC_PORT + value: {{ .Values.laminar.appServer.service.grpcPort | quote }} + - name: DATABASE_URL + value: {{ printf "postgres://%s:%s@%s:5432/%s" .Values.laminar.postgres.auth.username .Values.laminar.postgres.auth.password (include "centaur.componentName" (dict "root" . "component" "laminar-postgres")) .Values.laminar.postgres.auth.database | quote }} + - name: SHARED_SECRET_TOKEN + value: {{ .Values.laminar.sharedSecretToken | quote }} + - name: CLICKHOUSE_URL + value: {{ printf "http://%s:%v" (include "centaur.componentName" (dict "root" . "component" "laminar-clickhouse")) .Values.laminar.clickhouse.service.httpPort | quote }} + - name: CLICKHOUSE_USER + value: {{ .Values.laminar.clickhouse.auth.user | quote }} + - name: CLICKHOUSE_PASSWORD + value: {{ .Values.laminar.clickhouse.auth.password | quote }} + - name: CLICKHOUSE_RO_USER + value: {{ .Values.laminar.clickhouse.auth.readOnlyUser | quote }} + - name: CLICKHOUSE_RO_PASSWORD + value: {{ .Values.laminar.clickhouse.auth.readOnlyPassword | quote }} + - name: ENVIRONMENT + value: LITE + - name: AEAD_SECRET_KEY + value: {{ .Values.laminar.aeadSecretKey | quote }} + - name: QUERY_ENGINE_URL + value: {{ printf "http://%s:%v" (include "centaur.componentName" (dict "root" . "component" "laminar-query-engine")) .Values.laminar.queryEngine.service.port | quote }} + - name: QUICKWIT_SEARCH_URL + value: {{ printf "http://%s:%v" (include "centaur.componentName" (dict "root" . "component" "laminar-quickwit")) .Values.laminar.quickwit.service.httpPort | quote }} + - name: QUICKWIT_INGEST_URL + value: {{ printf "http://%s:%v" (include "centaur.componentName" (dict "root" . "component" "laminar-quickwit")) .Values.laminar.quickwit.service.grpcPort | quote }} + - name: QUICKWIT_SPANS_INDEX_ID + value: spans_v2 +{{- range $name, $value := .Values.laminar.extraEnv }} + - name: {{ $name }} + value: {{ $value | quote }} +{{- end }} + ports: + - name: http + containerPort: {{ .Values.laminar.appServer.service.httpPort }} + - name: grpc + containerPort: {{ .Values.laminar.appServer.service.grpcPort }} + - name: realtime + containerPort: {{ .Values.laminar.appServer.service.realtimePort }} + readinessProbe: + tcpSocket: + port: {{ .Values.laminar.appServer.service.httpPort }} + failureThreshold: 30 + resources: +{{ toYaml .Values.laminar.appServer.resources | nindent 12 }} +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + name: {{ include "centaur.componentName" (dict "root" . "component" "laminar-frontend") }} + labels: +{{ include "centaur.componentLabels" (dict "root" . "component" "laminar-frontend") | nindent 4 }} +spec: + replicas: 1 + selector: + matchLabels: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-frontend") | nindent 6 }} + template: + metadata: + labels: +{{ include "centaur.componentSelectorLabels" (dict "root" . "component" "laminar-frontend") | nindent 8 }} + spec: + automountServiceAccountToken: false + initContainers: + - name: wait-for-laminar-dependencies + image: {{ printf "%s:%s" .Values.laminar.waitImage.repository .Values.laminar.waitImage.tag | quote }} + imagePullPolicy: {{ .Values.laminar.waitImage.pullPolicy }} + command: + - /bin/sh + - -ec + - | + for target in \ + {{ include "centaur.componentName" (dict "root" . "component" "laminar-postgres") }}:5432 \ + {{ include "centaur.componentName" (dict "root" . "component" "laminar-clickhouse") }}:{{ .Values.laminar.clickhouse.service.httpPort }} \ + {{ include "centaur.componentName" (dict "root" . "component" "laminar-quickwit") }}:{{ .Values.laminar.quickwit.service.httpPort }} \ + {{ include "centaur.componentName" (dict "root" . "component" "laminar-app-server") }}:{{ .Values.laminar.appServer.service.httpPort }} + do + host="${target%:*}" + port="${target##*:}" + until nc -z "$host" "$port"; do + sleep 2 + done + done + containers: + - name: frontend + image: {{ printf "%s:%s" .Values.laminar.frontend.image.repository .Values.laminar.frontend.image.tag | quote }} + imagePullPolicy: {{ .Values.laminar.imagePullPolicy }} + env: + - name: DATABASE_URL + value: {{ printf "postgres://%s:%s@%s:5432/%s" .Values.laminar.postgres.auth.username .Values.laminar.postgres.auth.password (include "centaur.componentName" (dict "root" . "component" "laminar-postgres")) .Values.laminar.postgres.auth.database | quote }} + - name: PORT + value: {{ .Values.laminar.frontend.service.port | quote }} + - name: BACKEND_URL + value: {{ printf "http://%s:%v" (include "centaur.componentName" (dict "root" . "component" "laminar-app-server")) .Values.laminar.appServer.service.httpPort | quote }} + - name: BACKEND_RT_URL + value: {{ printf "http://%s:%v" (include "centaur.componentName" (dict "root" . "component" "laminar-app-server")) .Values.laminar.appServer.service.realtimePort | quote }} + - name: SHARED_SECRET_TOKEN + value: {{ .Values.laminar.sharedSecretToken | quote }} + - name: NEXTAUTH_URL + value: {{ .Values.laminar.publicUrl | quote }} + - name: NEXTAUTH_SECRET + value: {{ .Values.laminar.nextAuthSecret | quote }} + - name: NEXT_PUBLIC_URL + value: {{ .Values.laminar.publicUrl | quote }} + - name: ENVIRONMENT + value: LITE + - name: CLICKHOUSE_URL + value: {{ printf "http://%s:%v" (include "centaur.componentName" (dict "root" . "component" "laminar-clickhouse")) .Values.laminar.clickhouse.service.httpPort | quote }} + - name: CLICKHOUSE_USER + value: {{ .Values.laminar.clickhouse.auth.user | quote }} + - name: CLICKHOUSE_PASSWORD + value: {{ .Values.laminar.clickhouse.auth.password | quote }} + - name: CLICKHOUSE_RO_USER + value: {{ .Values.laminar.clickhouse.auth.readOnlyUser | quote }} + - name: CLICKHOUSE_RO_PASSWORD + value: {{ .Values.laminar.clickhouse.auth.readOnlyPassword | quote }} + - name: AEAD_SECRET_KEY + value: {{ .Values.laminar.aeadSecretKey | quote }} + - name: QUICKWIT_SEARCH_URL + value: {{ printf "http://%s:%v" (include "centaur.componentName" (dict "root" . "component" "laminar-quickwit")) .Values.laminar.quickwit.service.httpPort | quote }} +{{- range $name, $value := .Values.laminar.extraEnv }} + - name: {{ $name }} + value: {{ $value | quote }} +{{- end }} + ports: + - name: http + containerPort: {{ .Values.laminar.frontend.service.port }} + readinessProbe: + tcpSocket: + port: {{ .Values.laminar.frontend.service.port }} + failureThreshold: 30 + resources: +{{ toYaml .Values.laminar.frontend.resources | nindent 12 }} +{{- end }} diff --git a/contrib/chart/values.dev.yaml b/contrib/chart/values.dev.yaml index 3f1cc0a0c..97c0d34c4 100644 --- a/contrib/chart/values.dev.yaml +++ b/contrib/chart/values.dev.yaml @@ -31,9 +31,23 @@ ironProxy: manager: secretSource: onepassword +chatbot: + image: + pullPolicy: IfNotPresent + tokenBroker: - enabled: true + enabled: false sandbox: image: pullPolicy: IfNotPresent + +laminar: + enabled: true + appServer: + service: + httpPort: 8000 + grpcPort: 8001 + +networkPolicy: + enabled: false diff --git a/contrib/chart/values.yaml b/contrib/chart/values.yaml index c9e50f22c..6dbefddf6 100644 --- a/contrib/chart/values.yaml +++ b/contrib/chart/values.yaml @@ -247,3 +247,82 @@ containerSecurityContext: capabilities: drop: - ALL + +laminar: + enabled: false + imagePullPolicy: IfNotPresent + waitImage: + repository: busybox + tag: "1.36" + pullPolicy: IfNotPresent + frontend: + image: + repository: ghcr.io/lmnr-ai/frontend + tag: latest + service: + port: 5667 + resources: {} + appServer: + image: + repository: ghcr.io/lmnr-ai/app-server + tag: latest + service: + httpPort: 8000 + grpcPort: 8001 + realtimePort: 8002 + resources: {} + queryEngine: + image: + repository: ghcr.io/lmnr-ai/query-engine + tag: latest + service: + port: 8903 + resources: {} + quickwit: + image: + repository: quickwit/quickwit + tag: v0.8.2 + service: + httpPort: 7280 + grpcPort: 7281 + persistence: + enabled: true + size: 10Gi + storageClassName: "" + resources: {} + clickhouse: + image: + repository: clickhouse/clickhouse-server + tag: latest + service: + httpPort: 8123 + nativePort: 9000 + auth: + user: ch_user + password: ch_passwd + readOnlyUser: ch_user + readOnlyPassword: ch_passwd + persistence: + enabled: true + size: 20Gi + storageClassName: "" + resources: {} + postgres: + image: + repository: postgres + tag: "16" + auth: + username: postgres + password: postgres_passwordabc + database: postgres + persistence: + enabled: true + size: 10Gi + storageClassName: "" + resources: {} + sharedSecretToken: some_secret + nextAuthSecret: 0123456789abcdef0123456789abcdef + aeadSecretKey: 0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef + publicUrl: http://localhost:5667 + extraEnv: {} + diff --git a/services/api/api/laminar_tracing.py b/services/api/api/laminar_tracing.py new file mode 100644 index 000000000..fb25426e6 --- /dev/null +++ b/services/api/api/laminar_tracing.py @@ -0,0 +1,24 @@ +from __future__ import annotations + +from contextlib import contextmanager +from typing import Any + + +def set_trace_context( + *, + user_id: str | None = None, + session_id: str | None = None, + metadata: dict[str, Any] | None = None, +) -> None: + pass + + +@contextmanager +def start_span( + *, + name: str = "", + span_type: str = "DEFAULT", + metadata: dict[str, Any] | None = None, + trace_id: str | None = None, +): + yield