diff --git a/helm/pinot/templates/broker/statefulset.yaml b/helm/pinot/templates/broker/statefulset.yaml index 22ea8e49a0d5..80240db877af 100644 --- a/helm/pinot/templates/broker/statefulset.yaml +++ b/helm/pinot/templates/broker/statefulset.yaml @@ -24,6 +24,7 @@ metadata: namespace: {{ include "pinot.namespace" . }} labels: {{- include "pinot.brokerLabels" . | nindent 4 }} + annotations: {{ toYaml .Values.broker.annotations | nindent 4 }} spec: selector: matchLabels: @@ -65,7 +66,7 @@ spec: - name: broker securityContext: {{- toYaml .Values.broker.securityContext | nindent 10 }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" + image: "{{ .Values.brokerImage.repository | default .Values.image.repository }}:{{ .Values.brokerImage.tag | default .Values.image.tag }}" imagePullPolicy: {{ .Values.image.pullPolicy }} args: [ "{{ .Values.broker.startCommand }}", diff --git a/helm/pinot/templates/controller/statefulset.yaml b/helm/pinot/templates/controller/statefulset.yaml index b2403767f066..c05527381861 100644 --- a/helm/pinot/templates/controller/statefulset.yaml +++ b/helm/pinot/templates/controller/statefulset.yaml @@ -24,6 +24,7 @@ metadata: namespace: {{ include "pinot.namespace" . }} labels: {{- include "pinot.controllerLabels" . | nindent 4 }} + annotations: {{ toYaml .Values.controller.annotations | nindent 4 }} spec: selector: matchLabels: @@ -65,7 +66,7 @@ spec: - name: controller securityContext: {{- toYaml .Values.controller.securityContext | nindent 10 }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" + image: "{{ .Values.controllerImage.repository | default .Values.image.repository }}:{{ .Values.controllerImage.tag | default .Values.image.tag }}" imagePullPolicy: {{ .Values.image.pullPolicy }} args: [ "{{ .Values.controller.startCommand }}", "-configFileName", "/var/pinot/controller/config/pinot-controller.conf" ] env: diff --git a/helm/pinot/templates/minion-stateless/deployment.yaml b/helm/pinot/templates/minion-stateless/deployment.yaml index 9d59bd918f7b..ad41799c5d06 100644 --- a/helm/pinot/templates/minion-stateless/deployment.yaml +++ b/helm/pinot/templates/minion-stateless/deployment.yaml @@ -25,6 +25,7 @@ metadata: namespace: {{ include "pinot.namespace" . }} labels: {{- include "pinot.minionStatelessLabels" . | nindent 4 }} + annotations: {{ toYaml .Values.minionStateless.annotations | nindent 4 }} spec: selector: matchLabels: @@ -57,7 +58,7 @@ spec: - name: minion-stateless securityContext: {{- toYaml .Values.minionStateless.securityContext | nindent 10 }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" + image: "{{ .Values.minionImage.repository | default .Values.image.repository }}:{{ .Values.minionImage.tag | default .Values.image.tag }}" imagePullPolicy: {{ .Values.image.pullPolicy }} args: [ "{{ .Values.minionStateless.startCommand }}", diff --git a/helm/pinot/templates/minion/statefulset.yaml b/helm/pinot/templates/minion/statefulset.yaml index e8d2a786edd0..5d96a0bead01 100644 --- a/helm/pinot/templates/minion/statefulset.yaml +++ b/helm/pinot/templates/minion/statefulset.yaml @@ -25,6 +25,7 @@ metadata: namespace: {{ include "pinot.namespace" . }} labels: {{- include "pinot.minionLabels" . | nindent 4 }} + annotations: {{ toYaml .Values.minion.annotations | nindent 4 }} spec: selector: matchLabels: @@ -66,7 +67,7 @@ spec: - name: minion securityContext: {{- toYaml .Values.minion.securityContext | nindent 10 }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" + image: "{{ .Values.minionImage.repository | default .Values.image.repository }}:{{ .Values.minionImage.tag | default .Values.image.tag }}" imagePullPolicy: {{ .Values.image.pullPolicy }} args: [ "{{ .Values.minion.startCommand }}", diff --git a/helm/pinot/templates/namespace.yaml b/helm/pinot/templates/namespace.yaml new file mode 100644 index 000000000000..4d88a78316dc --- /dev/null +++ b/helm/pinot/templates/namespace.yaml @@ -0,0 +1,31 @@ +{{- if .Values.namespace.create }} +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +# + +apiVersion: v1 +kind: Namespace +metadata: + name: {{ include "pinot.namespace" . }} + labels: + {{- include "pinot.labels" . | nindent 4 }} + {{- with .Values.namespaceAnnotations }} + annotations: + {{- toYaml . | nindent 4 }} + {{- end }} +{{- end }} diff --git a/helm/pinot/templates/server/configmap.yaml b/helm/pinot/templates/server/configmap.yaml index e040b1a59b63..7e83ba5f07ab 100644 --- a/helm/pinot/templates/server/configmap.yaml +++ b/helm/pinot/templates/server/configmap.yaml @@ -24,10 +24,10 @@ metadata: namespace: {{ include "pinot.namespace" . }} data: pinot-server.conf: |- -{{ if .Values.server.ConfigureServerPort }} +{{- if .Values.server.ConfigureServerPort }} pinot.server.netty.port={{ .Values.server.service.nettyPort }} pinot.server.adminapi.port={{ .Values.server.service.adminPort }} -{{ end }} +{{- end }} pinot.server.instance.dataDir={{ .Values.server.dataDir }} pinot.server.instance.segmentTarDir={{ .Values.server.segmentTarDir }} {{ .Values.server.extra.configs | indent 4 }} diff --git a/helm/pinot/templates/server/statefulset.yaml b/helm/pinot/templates/server/statefulset.yaml index 724d0a4a20cc..86832376edc2 100644 --- a/helm/pinot/templates/server/statefulset.yaml +++ b/helm/pinot/templates/server/statefulset.yaml @@ -24,6 +24,7 @@ metadata: namespace: {{ include "pinot.namespace" . }} labels: {{- include "pinot.serverLabels" . | nindent 4 }} + annotations: {{ toYaml .Values.server.annotations | nindent 4 }} spec: selector: matchLabels: @@ -65,7 +66,7 @@ spec: - name: server securityContext: {{- toYaml .Values.server.securityContext | nindent 10 }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" + image: "{{ .Values.serverImage.repository | default .Values.image.repository }}:{{ .Values.serverImage.tag | default .Values.image.tag }}" imagePullPolicy: {{ .Values.image.pullPolicy }} args: [ "{{ .Values.server.startCommand }}", diff --git a/helm/pinot/values.yaml b/helm/pinot/values.yaml index 253cf61cb584..1276f9f04bf7 100644 --- a/helm/pinot/values.yaml +++ b/helm/pinot/values.yaml @@ -19,6 +19,8 @@ # Default values for Pinot. +namespace: + create: false namespaceOverride: namespaceAnnotations: {} @@ -35,6 +37,11 @@ image: tag: latest # 1.0.0, 0.12.1, latest pullPolicy: Always # Use IfNotPresent when you pinged a version of image tag +controllerImage: {} +brokerImage: {} +serverImage: {} +minionImage: {} + cluster: name: pinot-quickstart @@ -93,6 +100,7 @@ controller: # you want to specify the port in controller.access.protocols.https.port instead. configureControllerPort: true replicaCount: 1 + annotations: {} podManagementPolicy: Parallel podSecurityContext: {} # fsGroup: 2000 @@ -245,6 +253,7 @@ broker: # you want to specify the port in pinot.broker.access.protocols.https.port instead. configureBrokerPort: true replicaCount: 1 + annotations: {} podManagementPolicy: Parallel podSecurityContext: {} # fsGroup: 2000 @@ -389,6 +398,7 @@ server: # you want to specify the port in pinot.server.nettytls.port instead. configureServerPort: true replicaCount: 1 + annotations: {} podManagementPolicy: Parallel podSecurityContext: {} # fsGroup: 2000 @@ -523,6 +533,7 @@ minion: # or when you're configuring ports through another mechanism. configureMinionPort: true replicaCount: 0 + annotations: {} podManagementPolicy: Parallel podSecurityContext: {} # fsGroup: 2000 @@ -646,6 +657,7 @@ minionStateless: # or when you're configuring ports through another mechanism. configureMinionStatelessPort: true replicaCount: 1 + annotations: {} podSecurityContext: {} # fsGroup: 2000 securityContext: {}