Skip to content

Commit

Permalink
Fix missing envs key (#26)
Browse files Browse the repository at this point in the history
Co-authored-by: Azat Safin <azat@leetcode.com>
Co-authored-by: Azat Safin <azat.safin@gmail.com>
  • Loading branch information
3 people authored Oct 9, 2024
1 parent 212a3c1 commit ab4948b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
2 changes: 1 addition & 1 deletion charts/kafka-ui/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ apiVersion: v2
name: kafka-ui
description: A Helm chart for kafka-UI
type: application
version: 1.4.7
version: 1.4.8
appVersion: v1.0.0
icon: https://raw.githubusercontent.com/kafbat/kafka-ui/main/documentation/images/logo_new.png
13 changes: 8 additions & 5 deletions charts/kafka-ui/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,10 @@ spec:
{{- toYaml .Values.securityContext | nindent 12 }}
image: {{ include "kafka-ui.imageName" . }}
imagePullPolicy: {{ .Values.image.pullPolicy }}
{{- if or .Values.env .Values.yamlApplicationConfig .Values.yamlApplicationConfigConfigMap .Values.yamlApplicationConfigSecret }}
{{- if or .Values.env
.Values.yamlApplicationConfig .Values.yamlApplicationConfigConfigMap .Values.yamlApplicationConfigSecret
(.Values.envs).secretMappings (.Values.envs).configMappings
}}
env:
{{- with .Values.env }}
{{- toYaml . | nindent 12 }}
Expand All @@ -69,20 +72,20 @@ spec:
value: /kafka-ui/{{ .Values.yamlApplicationConfigSecret.keyName | default "config.yml" }}
{{- end }}
{{- end }}
{{- end }}
{{- range $key, $value := .Values.envs.secretMappings }}
{{- range $key, $value := .Values.envs.secretMappings }}
- name: {{ $key }}
valueFrom:
secretKeyRef:
name: {{ required "Missing required value envs.secretMappings.[].name" $value.name }}
key: {{ required "Missing required value envs.secretMappings.[].keyName" $value.keyName }}
{{- end }}
{{- range $key, $value := .Values.envs.configMappings }}
{{- end }}
{{- range $key, $value := .Values.envs.configMappings }}
- name: {{ $key }}
valueFrom:
configMapKeyRef:
name: {{ required "Missing required value envs.configMappings.[].name" $value.name }}
key: {{ required "Missing required value envs.configMappings.[].keyName" $value.keyName }}
{{- end }}
{{- end }}
{{- if or .Values.existingConfigMap .Values.envs.config .Values.existingSecret .Values.envs.secret }}
envFrom:
Expand Down

0 comments on commit ab4948b

Please sign in to comment.