diff --git a/charts/quickwit/Chart.yaml b/charts/quickwit/Chart.yaml index a6d0b5b..9cef5ee 100644 --- a/charts/quickwit/Chart.yaml +++ b/charts/quickwit/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v2 name: quickwit description: Sub-second search & analytics engine on cloud storage. type: application -version: 0.6.1 +version: 0.6.2 appVersion: "v0.8.1" keywords: - quickwit diff --git a/charts/quickwit/templates/_helpers.tpl b/charts/quickwit/templates/_helpers.tpl index 574d1a3..4421428 100644 --- a/charts/quickwit/templates/_helpers.tpl +++ b/charts/quickwit/templates/_helpers.tpl @@ -144,7 +144,7 @@ Quickwit environment fieldRef: fieldPath: status.podIP - name: QW_CONFIG - value: node.yaml + value: {{ .Values.configLocation }} - name: QW_CLUSTER_ID value: {{ .Release.Namespace }}-{{ include "quickwit.fullname" . }} - name: QW_NODE_ID diff --git a/charts/quickwit/templates/control-plane-deployment.yaml b/charts/quickwit/templates/control-plane-deployment.yaml index 4b93996..3d5648d 100644 --- a/charts/quickwit/templates/control-plane-deployment.yaml +++ b/charts/quickwit/templates/control-plane-deployment.yaml @@ -39,13 +39,21 @@ spec: serviceAccountName: {{ include "quickwit.serviceAccountName" . }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} + {{- with .Values.control_plane.initContainers }} + initContainers: + {{- toYaml . | nindent 8 }} + {{ end }} containers: - name: {{ .Chart.Name }} securityContext: {{- toYaml .Values.securityContext | nindent 12 }} image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" imagePullPolicy: {{ .Values.image.pullPolicy }} + {{- if $.Values.control_plane.args }} + args: {{- toYaml $.Values.control_plane.args | nindent 10 }} + {{- else }} args: ["run", "--service", "control_plane"] + {{- end }} env: {{- include "quickwit.environment" . | nindent 12 }} {{- range $key, $value := .Values.control_plane.extraEnv }} @@ -79,6 +87,9 @@ spec: - name: {{ .name }} mountPath: {{ .mountPath }} {{- end }} + {{- with .Values.indexer.extraVolumeMounts }} + {{- toYaml . | nindent 12 }} + {{- end }} resources: {{- toYaml .Values.control_plane.resources | nindent 14 }} volumes: @@ -95,6 +106,9 @@ spec: configMap: name: {{ .name }} {{- end }} + {{- with .Values.indexer.extraVolumes }} + {{- toYaml . | nindent 8 }} + {{- end }} {{- with .Values.control_plane.nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} diff --git a/charts/quickwit/templates/indexer-statefulset.yaml b/charts/quickwit/templates/indexer-statefulset.yaml index a41362d..7925567 100644 --- a/charts/quickwit/templates/indexer-statefulset.yaml +++ b/charts/quickwit/templates/indexer-statefulset.yaml @@ -43,12 +43,21 @@ spec: serviceAccountName: {{ include "quickwit.serviceAccountName" . }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} + {{- with .Values.indexer.initContainers }} + initContainers: + {{- toYaml . | nindent 8 }} + {{ end }} containers: - name: {{ .Chart.Name }} securityContext: {{- toYaml .Values.securityContext | nindent 12 }} image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" imagePullPolicy: {{ .Values.image.pullPolicy }} + {{- if $.Values.indexer.args }} + args: {{- toYaml $.Values.indexer.args | nindent 10 }} + {{- else }} + args: ["run", "--service", "indexer"] + {{- end }} env: {{- include "quickwit.environment" . | nindent 12 }} {{- range $key, $value := .Values.indexer.extraEnv }} @@ -64,7 +73,6 @@ spec: {{- toYaml . | nindent 12 }} {{- end }} {{- end }} - args: ["run", "--service", "indexer"] ports: {{- include "quickwit.ports" . | nindent 12 }} startupProbe: @@ -83,6 +91,9 @@ spec: - name: {{ .name }} mountPath: {{ .mountPath }} {{- end }} + {{- with .Values.indexer.extraVolumeMounts }} + {{- toYaml . | nindent 12 }} + {{- end }} resources: {{- toYaml .Values.indexer.resources | nindent 12 }} volumes: @@ -101,6 +112,9 @@ spec: configMap: name: {{ .name }} {{- end }} + {{- with .Values.indexer.extraVolumes }} + {{- toYaml . | nindent 8 }} + {{- end }} {{- with .Values.indexer.nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} diff --git a/charts/quickwit/templates/janitor-deployment.yaml b/charts/quickwit/templates/janitor-deployment.yaml index ac41ad7..6fb5dc9 100644 --- a/charts/quickwit/templates/janitor-deployment.yaml +++ b/charts/quickwit/templates/janitor-deployment.yaml @@ -40,13 +40,21 @@ spec: serviceAccountName: {{ include "quickwit.serviceAccountName" . }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} + {{- with .Values.janitor.initContainers }} + initContainers: + {{ toYaml . | nindent 8 }} + {{ end }} containers: - name: {{ .Chart.Name }} securityContext: {{- toYaml .Values.securityContext | nindent 12 }} image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" imagePullPolicy: {{ .Values.image.pullPolicy }} + {{- if $.Values.janitor.args }} + args: {{- toYaml $.Values.janitor.args | nindent 10 }} + {{- else }} args: ["run", "--service", "janitor"] + {{- end }} env: {{- include "quickwit.environment" . | nindent 12 }} {{- range $key, $value := .Values.janitor.extraEnv }} @@ -80,6 +88,9 @@ spec: - name: {{ .name }} mountPath: {{ .mountPath }} {{- end }} + {{- with .Values.indexer.extraVolumeMounts }} + {{- toYaml . | nindent 12 }} + {{- end }} resources: {{- toYaml .Values.janitor.resources | nindent 14 }} volumes: @@ -96,6 +107,9 @@ spec: configMap: name: {{ .name }} {{- end }} + {{- with .Values.indexer.extraVolumes }} + {{- toYaml . | nindent 8 }} + {{- end }} {{- with .Values.janitor.nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} diff --git a/charts/quickwit/templates/job-create-indices.yaml b/charts/quickwit/templates/job-create-indices.yaml index 675e438..1ded159 100644 --- a/charts/quickwit/templates/job-create-indices.yaml +++ b/charts/quickwit/templates/job-create-indices.yaml @@ -24,16 +24,25 @@ spec: imagePullSecrets: {{- toYaml . | nindent 8 }} {{- end }} + serviceAccountName: {{ include "quickwit.serviceAccountName" $ }} securityContext: {{- toYaml $.Values.podSecurityContext | nindent 8 }} restartPolicy: Never + {{- with $.Values.jobs.indexes.initContainers }} + initContainers: + {{- toYaml . | nindent 8 }} + {{ end }} containers: - name: {{ $.Chart.Name }} securityContext: {{- toYaml $.Values.securityContext | nindent 10 }} image: "{{ $.Values.image.repository }}:{{ $.Values.image.tag | default $.Chart.AppVersion }}" imagePullPolicy: {{ $.Values.image.pullPolicy }} + {{- if $.Values.jobs.indexes.command }} + command: {{- toYaml $.Values.jobs.sources.command | nindent 8 }} + {{- else }} command: ["/bin/bash","-c","quickwit index describe --index {{ .index_id }} --endpoint ${QW_CLUSTER_ENDPOINT} || quickwit index create --index-config {{ .index_id }}.yaml --endpoint ${QW_CLUSTER_ENDPOINT}"] + {{- end }} env: {{- include "quickwit.environment" $ | nindent 10 }} {{- range $key, $value := $.Values.bootstrap.extraEnv }} @@ -56,6 +65,9 @@ spec: - name: index mountPath: /quickwit/{{ .index_id }}.yaml subPath: {{ .index_id }}.yaml + {{- with $.Values.jobs.indexes.extraVolumeMounts }} + {{- toYaml . | nindent 10 }} + {{- end }} resources: {{- toYaml $.Values.bootstrap.resources | nindent 10 }} volumes: @@ -71,5 +83,20 @@ spec: items: - key: {{ .index_id }}.yaml path: {{ .index_id }}.yaml + {{- with $.Values.jobs.indexes.extraVolumes }} + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with $.Values.bootstrap.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with $.Values.bootstrap.affinity }} + affinity: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with $.Values.bootstrap.tolerations }} + tolerations: + {{- toYaml . | nindent 8 }} + {{- end }} {{- end }} {{- end }} diff --git a/charts/quickwit/templates/job-create-sources.yaml b/charts/quickwit/templates/job-create-sources.yaml index 8db18ff..96ce09b 100644 --- a/charts/quickwit/templates/job-create-sources.yaml +++ b/charts/quickwit/templates/job-create-sources.yaml @@ -24,16 +24,25 @@ spec: imagePullSecrets: {{- toYaml . | nindent 8 }} {{- end }} + serviceAccountName: {{ include "quickwit.serviceAccountName" $ }} securityContext: {{- toYaml $.Values.podSecurityContext | nindent 8 }} restartPolicy: Never + {{- with $.Values.jobs.sources.initContainers }} + initContainers: + {{- toYaml . | nindent 8 }} + {{ end }} containers: - name: {{ $.Chart.Name }} securityContext: {{- toYaml $.Values.securityContext | nindent 10 }} image: "{{ $.Values.image.repository }}:{{ $.Values.image.tag | default $.Chart.AppVersion }}" imagePullPolicy: {{ $.Values.image.pullPolicy }} - command: ["/bin/bash","-c","quickwit source describe --index {{ .index }} --source {{ .source.source_id }} --endpoint ${QW_CLUSTER_ENDPOINT}|| quickwit source create --index {{ .index }} --source-config {{ .source.source_id }}.yaml --endpoint ${QW_CLUSTER_ENDPOINT}"] + {{- if $.Values.jobs.sources.command }} + command: {{- toYaml $.Values.jobs.sources.command | nindent 8 }} + {{- else }} + command: ["/bin/bash","-c","quickwit source describe --index {{ .index }} --source {{ .source.source_id }} --endpoint ${QW_CLUSTER_ENDPOINT} || quickwit source create --index {{ .index }} --source-config {{ .source.source_id }}.yaml --endpoint ${QW_CLUSTER_ENDPOINT}"] + {{- end }} env: {{- include "quickwit.environment" $ | nindent 10 }} {{- range $key, $value := $.Values.bootstrap.extraEnv }} @@ -58,6 +67,9 @@ spec: mountPath: /quickwit/{{ .source.source_id }}.yaml subPath: {{ .source.source_id }}.yaml {{- end }} + {{- with $.Values.jobs.sources.extraVolumeMounts }} + {{- toYaml . | nindent 10 }} + {{- end }} resources: {{- toYaml $.Values.bootstrap.resources | nindent 10 }} volumes: @@ -73,5 +85,20 @@ spec: items: - key: {{ .source.source_id }}.yaml path: {{ .source.source_id }}.yaml + {{- with $.Values.jobs.sources.extraVolumes }} + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with $.Values.bootstrap.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with $.Values.bootstrap.affinity }} + affinity: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with $.Values.bootstrap.tolerations }} + tolerations: + {{- toYaml . | nindent 8 }} + {{- end }} {{- end }} {{- end }} diff --git a/charts/quickwit/templates/metastore-deployment.yaml b/charts/quickwit/templates/metastore-deployment.yaml index 39f446f..3b19071 100644 --- a/charts/quickwit/templates/metastore-deployment.yaml +++ b/charts/quickwit/templates/metastore-deployment.yaml @@ -38,13 +38,21 @@ spec: serviceAccountName: {{ include "quickwit.serviceAccountName" . }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} + {{- with .Values.metastore.initContainers }} + initContainers: + {{- toYaml . | nindent 8 }} + {{ end }} containers: - name: {{ .Chart.Name }} securityContext: {{- toYaml .Values.securityContext | nindent 12 }} image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} + imagePullPolicy: {{ .Values.image.pullPolicy }} + {{- if $.Values.metastore.args }} + args: {{- toYaml $.Values.metastore.args | nindent 10 }} + {{- else }} args: ["run", "--service", "metastore"] + {{- end }} env: {{- include "quickwit.environment" . | nindent 12 }} {{- range $key, $value := .Values.metastore.extraEnv }} @@ -78,6 +86,9 @@ spec: - name: {{ .name }} mountPath: {{ .mountPath }} {{- end }} + {{- with .Values.metastore.extraVolumeMounts }} + {{- toYaml . | nindent 12 }} + {{- end }} resources: {{- toYaml .Values.metastore.resources | nindent 14 }} volumes: @@ -94,6 +105,9 @@ spec: configMap: name: {{ .name }} {{- end }} + {{- with .Values.metastore.extraVolumes }} + {{- toYaml . | nindent 10 }} + {{- end }} {{- with .Values.metastore.nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} diff --git a/charts/quickwit/templates/searcher-statefulset.yaml b/charts/quickwit/templates/searcher-statefulset.yaml index 072dd70..8b977cf 100644 --- a/charts/quickwit/templates/searcher-statefulset.yaml +++ b/charts/quickwit/templates/searcher-statefulset.yaml @@ -43,12 +43,21 @@ spec: serviceAccountName: {{ include "quickwit.serviceAccountName" . }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} + {{- with .Values.searcher.initContainers }} + initContainers: + {{- toYaml . | nindent 8 }} + {{ end }} containers: - name: {{ .Chart.Name }} securityContext: {{- toYaml .Values.securityContext | nindent 12 }} image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" imagePullPolicy: {{ .Values.image.pullPolicy }} + {{- if $.Values.searcher.args }} + args: {{- toYaml $.Values.searcher.args | nindent 10 }} + {{- else }} + args: ["run", "--service", "searcher"] + {{- end }} env: {{- include "quickwit.environment" . | nindent 12 }} {{- range $key, $value := .Values.searcher.extraEnv }} @@ -64,7 +73,6 @@ spec: {{- toYaml . | nindent 12 }} {{- end }} {{- end }} - args: ["run", "--service", "searcher"] ports: {{- include "quickwit.ports" . | nindent 12 }} startupProbe: @@ -83,6 +91,9 @@ spec: - name: {{ .name }} mountPath: {{ .mountPath }} {{- end }} + {{- with .Values.searcher.extraVolumeMounts }} + {{- toYaml . | nindent 12 }} + {{- end }} resources: {{- toYaml .Values.searcher.resources | nindent 14 }} volumes: @@ -101,6 +112,9 @@ spec: configMap: name: {{ .name }} {{- end }} + {{- with .Values.searcher.extraVolumes }} + {{- toYaml . | nindent 10 }} + {{- end }} {{- with .Values.searcher.nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} diff --git a/charts/quickwit/values.yaml b/charts/quickwit/values.yaml index 471e974..c78cccd 100644 --- a/charts/quickwit/values.yaml +++ b/charts/quickwit/values.yaml @@ -61,6 +61,12 @@ searcher: # - configMapRef: # name: quickwit-searcher + # extraVolumes -- Additional Volumes to use with Vector Pods. + extraVolumes: [] + + # extraVolumeMounts -- Additional Volume to mount into Vector Containers. + extraVolumeMounts: [] + resources: {} # limits: # cpu: 100m @@ -99,6 +105,12 @@ searcher: path: /health/readyz port: rest + # Override args for starting container + args: [] + + # initContainers -- Init Containers to be added to the pods + initContainers: [] + annotations: {} podAnnotations: {} @@ -125,6 +137,12 @@ indexer: # - configMapRef: # name: quickwit-indexer + # extraVolumes -- Additional Volumes to use with Vector Pods. + extraVolumes: [] + + # extraVolumeMounts -- Additional Volume to mount into Vector Containers. + extraVolumeMounts: [] + resources: {} # limits: # cpu: 100m @@ -158,6 +176,12 @@ indexer: path: /health/readyz port: rest + # Override args for starting container + args: [] + + # initContainers -- Init Containers to be added to the pods + initContainers: [] + annotations: {} podAnnotations: {} @@ -190,6 +214,12 @@ metastore: # - configMapRef: # name: quickwit-metastore + # extraVolumes -- Additional Volumes to use with Vector Pods. + extraVolumes: [] + + # extraVolumeMounts -- Additional Volume to mount into Vector Containers. + extraVolumeMounts: [] + resources: {} # limits: # cpu: 100m @@ -218,6 +248,12 @@ metastore: path: /health/readyz port: rest + # Override args for starting container + args: [] + + # initContainers -- Init Containers to be added to the pods + initContainers: [] + annotations: {} podAnnotations: {} @@ -242,6 +278,12 @@ control_plane: # - configMapRef: # name: quickwit-control-plane + # extraVolumes -- Additional Volumes to use with Vector Pods. + extraVolumes: [] + + # extraVolumeMounts -- Additional Volume to mount into Vector Containers. + extraVolumeMounts: [] + resources: {} # limits: # cpu: 100m @@ -267,6 +309,12 @@ control_plane: path: /health/readyz port: rest + # Override args for starting container + args: [] + + # initContainers -- Init Containers to be added to the pods + initContainers: [] + annotations: {} podAnnotations: {} @@ -294,6 +342,12 @@ janitor: # - configMapRef: # name: quickwit-janitor + # extraVolumes -- Additional Volumes to use with Vector Pods. + extraVolumes: [] + + # extraVolumeMounts -- Additional Volume to mount into Vector Containers. + extraVolumeMounts: [] + resources: {} # limits: # cpu: 100m @@ -319,6 +373,12 @@ janitor: path: /health/readyz port: rest + # Override args for starting container + args: [] + + # initContainers -- Init Containers to be added to the pods + initContainers: [] + annotations: {} podAnnotations: {} @@ -347,6 +407,12 @@ bootstrap: # - configMapRef: # name: quickwit-boostrap + # extraVolumes -- Additional Volumes to use with Vector Pods. + extraVolumes: [] + + # extraVolumeMounts -- Additional Volume to mount into Vector Containers. + extraVolumeMounts: [] + resources: {} # limits: # cpu: 100m @@ -355,17 +421,45 @@ bootstrap: # cpu: 100m # memory: 128Mi + # initContainers -- Init Containers to be added to the pods + initContainers: [] + nodeSelector: {} tolerations: [] affinity: {} +jobs: + sources: + # Override command for starting container + command: [] + + # initContainers -- Init Containers to be added to the pods + initContainers: [] + + # extraVolumes -- Additional Volumes to use with quickwit Pods. + extraVolumes: [] + + # extraVolumeMounts -- Additional Volume to mount into quickwit Containers. + extraVolumeMounts: [] + + indexes: + # initContainers -- Init Containers to be added to the pods + initContainers: [] + + # extraVolumes -- Additional Volumes to use with quickwit Pods. + extraVolumes: [] + + # extraVolumeMounts -- Additional Volume to mount into quickwit Containers. + extraVolumeMounts: [] # Quickwit configuration # Warning: This config is writed directly into a configMap # to avoid passing sensitive value you can pass environment variables. # https://quickwit.io/docs/configuration/node-config#using-environment-variables-in-the-configuration +configLocation: /quickwit/node.yaml + config: version: 0.8 listen_address: 0.0.0.0