Skip to content

Commit 938ee9e

Browse files
ericreevescognifloyd
authored andcommitted
Check for volumes.enabled before checking for images
1 parent 7be8ebc commit 938ee9e

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

templates/_helpers.tpl

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -138,31 +138,31 @@ Create the name of the stackstorm-ha service account to use
138138

139139
# For custom st2packs-Container reduce duplicity by defining it here once
140140
{{- define "packs-volumes" -}}
141-
{{- if .Values.st2.packs.images }}
142-
- name: st2-packs-vol
143-
emptyDir: {}
144-
- name: st2-virtualenvs-vol
145-
emptyDir: {}
146-
{{- else if .Values.st2.packs.volumes.enabled }}
141+
{{- if .Values.st2.packs.volumes.enabled }}
147142
- name: st2-packs-vol
148143
{{ toYaml .Values.st2.packs.volumes.packs | indent 2 }}
149144
- name: st2-virtualenvs-vol
150145
{{ toYaml .Values.st2.packs.volumes.virtualenvs | indent 2 }}
146+
{{- else if .Values.st2.packs.images }}
147+
- name: st2-packs-vol
148+
emptyDir: {}
149+
- name: st2-virtualenvs-vol
150+
emptyDir: {}
151151
{{- end }}
152152
{{- end -}}
153153
{{- define "packs-volume-mounts" -}}
154-
{{- if .Values.st2.packs.images }}
154+
{{- if .Values.st2.packs.volumes.enabled }}
155155
- name: st2-packs-vol
156156
mountPath: /opt/stackstorm/packs
157-
readOnly: true
158157
- name: st2-virtualenvs-vol
159158
mountPath: /opt/stackstorm/virtualenvs
160-
readOnly: true
161-
{{- else if .Values.st2.packs.volumes.enabled }}
159+
{{- else if .Values.st2.packs.images }}
162160
- name: st2-packs-vol
163161
mountPath: /opt/stackstorm/packs
162+
readOnly: true
164163
- name: st2-virtualenvs-vol
165164
mountPath: /opt/stackstorm/virtualenvs
165+
readOnly: true
166166
{{- end }}
167167
{{- end -}}
168168
# define this here as well to simplify comparison with packs-volume-mounts

0 commit comments

Comments
 (0)