From 07cf99a04fd17325f8d571caa42867c846989875 Mon Sep 17 00:00:00 2001 From: Liya Katz Date: Thu, 16 Jan 2025 22:30:08 +0200 Subject: [PATCH] OPIK-802: add an option to use external clickhouse (#1065) * OPIK-802: add an option to use external clickhouse * Update Helm documentation --------- Co-authored-by: CometActions --- deployment/helm_chart/opik/Chart.lock | 6 +++--- deployment/helm_chart/opik/Chart.yaml | 1 + deployment/helm_chart/opik/README.md | 1 + .../opik/templates/clickhouse-backup-cronjob.yaml | 2 +- .../helm_chart/opik/templates/clickhouseinstallation.yaml | 2 ++ deployment/helm_chart/opik/values.yaml | 1 + 6 files changed, 9 insertions(+), 4 deletions(-) diff --git a/deployment/helm_chart/opik/Chart.lock b/deployment/helm_chart/opik/Chart.lock index cdf752a2f0..de7bfb9b32 100644 --- a/deployment/helm_chart/opik/Chart.lock +++ b/deployment/helm_chart/opik/Chart.lock @@ -13,6 +13,6 @@ dependencies: version: 0.23.7 - name: common repository: oci://registry-1.docker.io/bitnamicharts - version: 2.27.0 -digest: sha256:abbf693f77864eb242acd9cce31514c3c4335c0a52f10471ac8d43a67c02e0d4 -generated: "2024-11-17T14:25:02.348737+02:00" + version: 2.29.0 +digest: sha256:0f823c2e6559110ba3b340131758755ddd0f8f50322365f955a84e5edf8f7e1c +generated: "2025-01-16T21:46:20.505686+02:00" diff --git a/deployment/helm_chart/opik/Chart.yaml b/deployment/helm_chart/opik/Chart.yaml index eee29befca..ad04cdde36 100644 --- a/deployment/helm_chart/opik/Chart.yaml +++ b/deployment/helm_chart/opik/Chart.yaml @@ -42,6 +42,7 @@ dependencies: - name: altinity-clickhouse-operator version: "0.23.7" repository: https://docs.altinity.com/clickhouse-operator/ + condition: clickhouse.enabled - name: common version: 2.x.x repository: oci://registry-1.docker.io/bitnamicharts diff --git a/deployment/helm_chart/opik/README.md b/deployment/helm_chart/opik/README.md index d619e3609f..8a2262e7ce 100644 --- a/deployment/helm_chart/opik/README.md +++ b/deployment/helm_chart/opik/README.md @@ -95,6 +95,7 @@ Call opik api on http://localhost:5173/api | clickhouse.adminUser.username | string | `"opik"` | | | clickhouse.backup.enabled | bool | `false` | | | clickhouse.backup.successfulJobsHistoryLimit | int | `1` | | +| clickhouse.enabled | bool | `true` | | | clickhouse.image | string | `"altinity/clickhouse-server:24.3.5.47.altinitystable"` | | | clickhouse.logsLevel | string | `"information"` | | | clickhouse.monitoring.enabled | bool | `false` | | diff --git a/deployment/helm_chart/opik/templates/clickhouse-backup-cronjob.yaml b/deployment/helm_chart/opik/templates/clickhouse-backup-cronjob.yaml index a2970c081d..8f58904f5d 100644 --- a/deployment/helm_chart/opik/templates/clickhouse-backup-cronjob.yaml +++ b/deployment/helm_chart/opik/templates/clickhouse-backup-cronjob.yaml @@ -1,4 +1,4 @@ -{{ if .Values.clickhouse.backup.enabled }} +{{ if and .Values.clickhouse.enabled .Values.clickhouse.backup.enabled }} apiVersion: batch/v1 kind: CronJob metadata: diff --git a/deployment/helm_chart/opik/templates/clickhouseinstallation.yaml b/deployment/helm_chart/opik/templates/clickhouseinstallation.yaml index e2fcbcb4c5..da73b0944b 100644 --- a/deployment/helm_chart/opik/templates/clickhouseinstallation.yaml +++ b/deployment/helm_chart/opik/templates/clickhouseinstallation.yaml @@ -1,3 +1,4 @@ +{{- if .Values.clickhouse.enabled }} apiVersion: clickhouse.altinity.com/v1 kind: ClickHouseInstallation metadata: @@ -110,3 +111,4 @@ spec: resources: requests: storage: {{ .Values.clickhouse.storage }} +{{- end }} \ No newline at end of file diff --git a/deployment/helm_chart/opik/values.yaml b/deployment/helm_chart/opik/values.yaml index efd010de96..f0b4a6bfe5 100644 --- a/deployment/helm_chart/opik/values.yaml +++ b/deployment/helm_chart/opik/values.yaml @@ -204,6 +204,7 @@ altinity-clickhouse-operator: enabled: false clickhouse: + enabled: true shardsCount: 1 replicasCount: 1 image: altinity/clickhouse-server:24.3.5.47.altinitystable