diff --git a/stable/yugaware/templates/configs.yaml b/stable/yugaware/templates/configs.yaml index 599743ce60..728df606c9 100644 --- a/stable/yugaware/templates/configs.yaml +++ b/stable/yugaware/templates/configs.yaml @@ -1,19 +1,4 @@ # Copyright (c) YugaByte, Inc. ---- -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ .Release.Name }}-yugaware-global-config - labels: - app: {{ template "yugaware.name" . }} - chart: {{ template "yugaware.chart" . }} - release: {{ .Release.Name }} - heritage: {{ .Values.helm2Legacy | ternary "Tiller" (.Release.Service | quote) }} -data: - postgres_user: "postgres" - postgres_password: "{{ include "getOrGeneratePassword" (dict "Namespace" .Release.Namespace "Kind" "ConfigMap" "Name" (printf "%s%s" .Release.Name "-yugaware-global-config") "Key" "postgres_password") }}" - postgres_db: "yugaware" - app_secret: "{{ b64enc (randAlphaNum 64) }}" --- apiVersion: v1 diff --git a/stable/yugaware/templates/global-config.yaml b/stable/yugaware/templates/global-config.yaml new file mode 100644 index 0000000000..cfb267060c --- /dev/null +++ b/stable/yugaware/templates/global-config.yaml @@ -0,0 +1,17 @@ +# Copyright (c) YugaByte, Inc. + +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ .Release.Name }}-yugaware-global-config + labels: + app: {{ template "yugaware.name" . }} + chart: {{ template "yugaware.chart" . }} + release: {{ .Release.Name }} + heritage: {{ .Values.helm2Legacy | ternary "Tiller" (.Release.Service | quote) }} +data: + postgres_user: "postgres" + postgres_password: "{{ include "getOrGeneratePassword" (dict "Namespace" .Release.Namespace "Kind" "ConfigMap" "Name" (printf "%s%s" .Release.Name "-yugaware-global-config") "Key" "postgres_password") }}" + postgres_db: "yugaware" + app_secret: "{{ b64enc (randAlphaNum 64) }}" diff --git a/stable/yugaware/templates/statefulset.yaml b/stable/yugaware/templates/statefulset.yaml index de9315e50e..d64779602e 100644 --- a/stable/yugaware/templates/statefulset.yaml +++ b/stable/yugaware/templates/statefulset.yaml @@ -20,6 +20,8 @@ spec: metadata: labels: app: {{ .Release.Name }}-yugaware + annotations: + checksum/config: {{ include (print $.Template.BasePath "/configs.yaml") . | sha256sum }} spec: serviceAccountName: {{ .Release.Name }} imagePullSecrets: