Skip to content

Commit

Permalink
fix for clickhouse loadbalancer (#220)
Browse files Browse the repository at this point in the history
* fix for clickhouse loadbalancer

* small helm docs update

* Update Helm documentation

---------

Co-authored-by: CometActions <[email protected]>
  • Loading branch information
liyaka and CometActions authored Sep 11, 2024
1 parent 5c338ed commit ffb1c7d
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 15 deletions.
4 changes: 1 addition & 3 deletions deployment/helm_chart/opik/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,7 @@ helm repo add bitnami https://charts.bitnami.com/bitnami
helm dependency build
VERSION=0.1.0
helm upgrade --install opik -n opik --create-namespace -f values.yaml \
--set component.backend.image.tag=$VERSION --set component.frontend.image.tag=$VERSION \
--set component.backend.env.ANALYTICS_DB_MIGRATIONS_PASS=opik --set component.backend.env.ANALYTICS_DB_PASS=opik \
--set component.backend.env.STATE_DB_PASS=opik
--set component.backend.image.tag=$VERSION --set component.frontend.image.tag=$VERSION
```

## Open application
Expand Down
4 changes: 1 addition & 3 deletions deployment/helm_chart/opik/README.md.gotmpl
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,7 @@ helm repo add bitnami https://charts.bitnami.com/bitnami
helm dependency build
VERSION=0.1.0
helm upgrade --install opik -n opik --create-namespace -f values.yaml \
--set component.backend.image.tag=$VERSION --set component.frontend.image.tag=$VERSION \
--set component.backend.env.ANALYTICS_DB_MIGRATIONS_PASS=opik --set component.backend.env.ANALYTICS_DB_PASS=opik \
--set component.backend.env.STATE_DB_PASS=opik
--set component.backend.image.tag=$VERSION --set component.frontend.image.tag=$VERSION
```

## Open application
Expand Down
18 changes: 9 additions & 9 deletions deployment/helm_chart/opik/templates/clickhouseinstallation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,13 @@ metadata:
component: clickhouse
{{- include "opik.labels" $ | nindent 4 }}
spec:
defaults:
templates:
podTemplate: clickhouse-cluster-pod-template
serviceTemplate: {{ .Values.clickhouse.service.serviceTemplate }}
volumeClaimTemplate: storage-vc-template
configuration:
users:
# TODO change for local
{{- if .Values.clickhouse.adminUser.useSecret.enabled }}
{{ .Values.clickhouse.adminUser.username }}/k8s_secret_password: {{ include "opik.name" .}}-{{ .Values.clickhouse.adminUser.secretname }}/{{ .Values.clickhouse.adminUser.password_key }}
{{- else }}
Expand All @@ -31,12 +35,12 @@ spec:
shardsCount: {{ .Values.clickhouse.shardsCount }}
replicasCount: {{ .Values.clickhouse.replicasCount }}
templates:
podTemplate: clickhouse-stable
podTemplate: clickhouse-cluster-pod-template
serviceTemplate: {{ .Values.clickhouse.service.serviceTemplate }}
volumeClaimTemplate: storage-vc-template
templates:
podTemplates:
- name: clickhouse-stable
- name: clickhouse-cluster-pod-template
spec:
containers:
- name: clickhouse
Expand Down Expand Up @@ -71,8 +75,10 @@ spec:
ports:
- name: http
port: 8123
targetPort: 8123
- name: tcp
port: 9000
targetPort: 9000
type: LoadBalancer

volumeClaimTemplates:
Expand All @@ -86,9 +92,3 @@ spec:
resources:
requests:
storage: {{ .Values.clickhouse.storage }}

defaults:
templates:
podTemplate: clickhouse-cluster-pod-template
serviceTemplate: clickhouse-cluster-svc-template

0 comments on commit ffb1c7d

Please sign in to comment.