[incubator/couchdb] fix env vars for db container (#15162)

Fixes environment variables not being set correctly for the
couchdb container when `.Values.enableSearch` is `false` (the
default).

The feature toggle for search excluded the search container from the
statefulset but did not exclude the associated environment variables.
The result of this was a duplicate `env` field for the `couchdb`
container which would override the correct `env` field; for example,
`ERL_FLAGS` would not be passed to the container.

This comment fixes the scoping of the `.Values.enableSearch` feature
toggle to include the `env` fields for the `clouseau` container.

Signed-off-by: Will Holley <willholley@apache.org>
This commit is contained in:
Will Holley
2019-07-05 00:00:40 -07:00
committed by Kubernetes Prow Robot
parent e454f28bb5
commit f803af734e
2 changed files with 6 additions and 6 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
apiVersion: v1
name: couchdb
version: 1.2.1
version: 1.2.2
appVersion: 2.3.1
description: A database featuring seamless multi-master sync, that scales from
big data to mobile, with an intuitive HTTP/JSON API and designed for
+5 -5
View File
@@ -98,11 +98,6 @@ spec:
- name: couchdb-statefulset-assembler
image: "{{ .Values.helperImage.repository }}:{{ .Values.helperImage.tag }}"
imagePullPolicy: {{ .Values.helperImage.pullPolicy }}
{{- if .Values.enableSearch }}
- name: clouseau
image: "{{ .Values.searchImage.repository }}:{{ .Values.searchImage.tag }}"
imagePullPolicy: {{ .Values.searchImage.pullPolicy }}
{{- end }}
{{- if not .Values.allowAdminParty }}
env:
- name: COUCHDB_USER
@@ -116,6 +111,11 @@ spec:
name: {{ template "couchdb.fullname" . }}
key: adminPassword
{{- end }}
{{- if .Values.enableSearch }}
- name: clouseau
image: "{{ .Values.searchImage.repository }}:{{ .Values.searchImage.tag }}"
imagePullPolicy: {{ .Values.searchImage.pullPolicy }}
{{- end }}
{{- if .Values.nodeSelector }}
nodeSelector:
{{ toYaml .Values.nodeSelector | indent 8 }}