consolidate config-map

This commit is contained in:
Clint Shryock 2018-11-19 14:49:30 -06:00
parent 0d3280254c
commit b0944d48df
No known key found for this signature in database
GPG key ID: B7C8F9C70EC5CD29
4 changed files with 6 additions and 21 deletions

View file

@ -11,5 +11,5 @@ metadata:
release: {{ .Release.Name }}
data:
statefulconfig-from-values.hcl: |-
{{ tpl .Values.server.statefulConfig . | indent 4 }}
{{ tpl .Values.server.config . | indent 4 }}
{{- end }}

View file

@ -1,15 +0,0 @@
# StatefulSet to run the actual vault server cluster.
{{- if (or (and (ne (.Values.consulHA.enabled | toString) "-") .Values.consulHA.enabled) (and (eq (.Values.consulHA.enabled | toString) "-") .Values.global.enabled)) }}
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ template "vault.fullname" . }}-ha-config
labels:
app: {{ template "vault.name" . }}
chart: {{ template "vault.chart" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
data:
storageconfig-from-values.hcl: |-
{{ tpl .Values.consulHA.storageConfig . | indent 4 }}
{{- end }}

View file

@ -39,7 +39,7 @@ spec:
volumes:
- name: config
configMap:
name: {{ template "vault.fullname" . }}-ha-config
name: {{ template "vault.fullname" . }}-server-config
defaultMode: 0755
{{- range .Values.consulHA.extraVolumes }}
- name: userconfig-{{ .name }}

View file

@ -37,12 +37,12 @@ server:
# By default no direct resource request is made.
resources: {}
# statefulConfig is a raw string of default configuration when using a Stateful
# config is a raw string of default configuration when using a Stateful
# deployment. Default is to use a PersistentVolumeClaim mounted at /vault/data
# and store data there. This is only used when using a Replica count of 1, and
# using a stateful set
# This should be HCL
statefulConfig: |
config: |
ui = true
listener "tcp" {
tls_disable = 1
@ -77,12 +77,12 @@ consulHA:
# By default no direct resource request is made.
resources: {}
# statefulConfig is a raw string of default configuration when using a Stateful
# config is a raw string of default configuration when using a Stateful
# deployment. Default is to use a PersistentVolumeClaim mounted at /vault/data
# and store data there. This is only used when using a Replica count of 1, and
# using a stateful set
# This should be HCL
storageConfig: |
config: |
ui = true
listener "tcp" {
tls_disable = 1