Skip to content

Commit

Permalink
feat(charts/clickhouse): support additional configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
mjpitz committed May 27, 2024
1 parent f5dc651 commit 9f29c02
Show file tree
Hide file tree
Showing 5 changed files with 39 additions and 2 deletions.
2 changes: 1 addition & 1 deletion charts/clickhouse/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ description: |
(BETA) Deploy a standalone Clickhouse instance. ClickHouse is a high-performance, column-oriented SQL database
management system (DBMS) for online analytical processing (OLAP).
version: 0.2403.0
version: 0.2403.1

maintainers:
- name: Mya Pitzeruse
Expand Down
3 changes: 2 additions & 1 deletion charts/clickhouse/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# clickhouse

![Version: 0.2403.0](https://img.shields.io/badge/Version-0.2403.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square)
![Version: 0.2403.1](https://img.shields.io/badge/Version-0.2403.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square)

(BETA) Deploy a standalone Clickhouse instance. ClickHouse is a high-performance, column-oriented SQL database
management system (DBMS) for online analytical processing (OLAP).
Expand All @@ -19,6 +19,7 @@ management system (DBMS) for online analytical processing (OLAP).
| affinity | object | `{}` | Specify affinity rules for the pods. |
| auth.password | string | `"clickhouse"` | Specify the password used to authenticate with the clickhouse cluster. |
| auth.username | string | `"clickhouse"` | Specify the username used to authenticate with the clickhouse cluster. |
| extra.config | object | `{}` | Provide additional XML configuration to the clickhouse system. |
| fullnameOverride | string | `""` | Override the full name of the release. |
| image.pullPolicy | string | `"IfNotPresent"` | The pull policy to use for the image. |
| image.repository | string | `"clickhouse/clickhouse-server"` | The repository hosting the clickhouse image. |
Expand Down
15 changes: 15 additions & 0 deletions charts/clickhouse/templates/secret-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
apiVersion: v1
kind: Secret
metadata:
name: {{ include "clickhouse.fullname" . }}-configd
labels:
{{- include "clickhouse.labels" . | nindent 4 }}
{{- with .Values.extra.config }}
data:
{{- range $key, $value := . }}
{{ $key | quote }}: {{ $value | b64enc }}
{{- end }}
{{- else }}
data: {}
{{- end }}
6 changes: 6 additions & 0 deletions charts/clickhouse/templates/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ spec:
{{- else }}
emptyDir: {}
{{- end }}
- name: configd
secret:
secretName: {{ include "clickhouse.fullname" . }}-configd
containers:
- name: {{ .Chart.Name }}
securityContext:
Expand Down Expand Up @@ -84,6 +87,9 @@ spec:
volumeMounts:
- mountPath: /var/lib/clickhouse
name: data
- mountPath: /etc/clickhouse-server/config.d
name: configd
readOnly: true
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
Expand Down
15 changes: 15 additions & 0 deletions charts/clickhouse/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -97,3 +97,18 @@ persistence:

# -- Provide additional annotations to attach to the volume claim.
annotations: {}

extra:
# -- Provide additional XML configuration to the clickhouse system.
config:
# -- @ignore
docker_related_config.xml: |
<clickhouse>
<listen_host>::</listen_host>
<listen_host>0.0.0.0</listen_host>
<listen_try>1</listen_try>
<logger>
<console>1</console>
</logger>
</clickhouse>

0 comments on commit 9f29c02

Please sign in to comment.