blob: b35485f11c39cdecc4c3aef35cdfdd02f477e6bb [file] [log] [blame]
efiacor5c573312022-01-27 13:46:56 +00001{{/*
2# Copyright © 2022 Nordix Foundation
3#
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15*/}}
16apiVersion: kafka.strimzi.io/v1beta2
17kind: Kafka
efiacor57901a92022-11-14 16:17:15 +000018metadata: {{- include "common.resourceMetadata" . | nindent 2 }}
efiacor5c573312022-01-27 13:46:56 +000019spec:
20 kafka:
efiacor57901a92022-11-14 16:17:15 +000021 version: {{ .Values.config.kafkaVersion }}
efiacor5c573312022-01-27 13:46:56 +000022 replicas: {{ .Values.replicaCount }}
23 listeners:
24 - name: plain
efiacor57901a92022-11-14 16:17:15 +000025 port: {{ .Values.config.kafkaInternalPort }}
efiacor5c573312022-01-27 13:46:56 +000026 type: internal
27 tls: false
28 authentication:
efiacor57901a92022-11-14 16:17:15 +000029 type: {{ .Values.config.saslMechanism }}
efiacor5c573312022-01-27 13:46:56 +000030 - name: tls
31 port: 9093
32 type: internal
33 tls: true
34 authentication:
35 type: tls
36 - name: external
37 port: 9094
38 type: nodeport
39 tls: true
40 authentication:
41 type: tls
efiacoraf68a7e2022-04-08 10:59:52 +010042 configuration:
43 bootstrap:
Andreas Geissler8cd7e262022-09-13 13:24:50 +020044 nodePort: {{ .Values.global.nodePortPrefixExt }}93
efiacoraf68a7e2022-04-08 10:59:52 +010045 brokers:
46 - broker: 0
Andreas Geissler8cd7e262022-09-13 13:24:50 +020047 nodePort: {{ .Values.global.nodePortPrefixExt }}90
efiacoraf68a7e2022-04-08 10:59:52 +010048 - broker: 1
Andreas Geissler8cd7e262022-09-13 13:24:50 +020049 nodePort: {{ .Values.global.nodePortPrefixExt }}91
50 - broker: 2
51 nodePort: {{ .Values.global.nodePortPrefixExt }}92
efiacor5c573312022-01-27 13:46:56 +000052 authorization:
efiacor57901a92022-11-14 16:17:15 +000053 type: {{ .Values.config.authType }}
efiacor5c573312022-01-27 13:46:56 +000054 superUsers:
efiacor57901a92022-11-14 16:17:15 +000055 - {{ .Values.config.strimziKafkaAdminUser }}
efiacor5c573312022-01-27 13:46:56 +000056 template:
57 pod:
58 securityContext:
59 runAsUser: 0
60 fsGroup: 0
61 config:
efiacor23361a32022-03-14 13:44:02 +000062 default.replication.factor: {{ .Values.replicaCount }}
efiacor57901a92022-11-14 16:17:15 +000063 min.insync.replicas: {{ (eq 1.0 (.Values.replicaCount)) | ternary 1 (sub .Values.replicaCount 1) }}
efiacor5c573312022-01-27 13:46:56 +000064 offsets.topic.replication.factor: {{ .Values.replicaCount }}
efiacor57901a92022-11-14 16:17:15 +000065 num.partitions: {{ mul .Values.replicaCount 2 }}
efiacor5c573312022-01-27 13:46:56 +000066 transaction.state.log.replication.factor: {{ .Values.replicaCount }}
efiacor57901a92022-11-14 16:17:15 +000067 transaction.state.log.min.isr: {{ (eq 1.0 (.Values.replicaCount)) | ternary 1 (sub .Values.replicaCount 1) }}
68 log.message.format.version: {{ .Values.config.kafkaVersion }}
69 inter.broker.protocol.version: {{ .Values.config.kafkaVersion }}
efiacor5c573312022-01-27 13:46:56 +000070 storage:
71 type: jbod
efiacor5c573312022-01-27 13:46:56 +000072 volumes:
73 - id: 0
74 type: persistent-claim
efiacor57901a92022-11-14 16:17:15 +000075 size: {{ .Values.persistence.kafka.size }}
efiacorb7a43e22022-04-01 17:41:48 +010076 deleteClaim: true
efiacor57901a92022-11-14 16:17:15 +000077 class: {{ include "common.storageClass" (dict "dot" . "suffix" "kafka" "persistenceInfos" .Values.persistence.kafka) }}
efiacor5c573312022-01-27 13:46:56 +000078 zookeeper:
79 template:
80 pod:
81 securityContext:
82 runAsUser: 0
83 fsGroup: 0
84 replicas: {{ .Values.replicaCount }}
85 config:
86 ssl.hostnameVerification: false
efiacor1cfa2fb2022-06-01 16:02:39 +010087 ssl.quorum.hostnameVerification: false
Andreas Geissler485f6672022-04-06 13:12:48 +020088 {{- if (include "common.onServiceMesh" .) }}
89 sslQuorum: false
90 {{- end }}
efiacor5c573312022-01-27 13:46:56 +000091 storage:
92 type: persistent-claim
efiacor57901a92022-11-14 16:17:15 +000093 size: {{ .Values.persistence.zookeeper.size }}
efiacorb7a43e22022-04-01 17:41:48 +010094 deleteClaim: true
efiacor57901a92022-11-14 16:17:15 +000095 class: {{ include "common.storageClass" (dict "dot" . "suffix" "zk" "persistenceInfos" .Values.persistence.zookeeper) }}
efiacor5c573312022-01-27 13:46:56 +000096 entityOperator:
97 topicOperator: {}
98 userOperator: {}
99