Skip to content

Commit

Permalink
feat: add configuration for read-replica database
Browse files Browse the repository at this point in the history
  • Loading branch information
donch1989 committed Mar 22, 2024
1 parent 2957a6c commit bdf84a9
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 0 deletions.
7 changes: 7 additions & 0 deletions charts/core/templates/mgmt-backend/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,13 @@ data:
password: {{ default (include "core.database.rawPassword" .) .Values.database.external.password }}
host: {{ default (include "core.database.host" .) .Values.database.external.host }}
port: {{ default (include "core.database.port" .) .Values.database.external.port }}
{{- if .Values.database.external_replica }}
replica:
username: {{ .Values.database.external_replica.username | default "" }}
password: {{ .Values.database.external_replica.password | default "" }}
host: {{ .Values.database.external_replica.host | default "" }}
port: {{ .Values.database.external_replica.port | default "" }}
{{- end }}
name: mgmt
version: {{ .Values.mgmtBackend.dbVersion }}
timezone: Etc/UTC
Expand Down
7 changes: 7 additions & 0 deletions charts/core/templates/model-backend/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,13 @@ data:
password: {{ default (include "core.database.rawPassword" .) .Values.database.external.password }}
host: {{ default (include "core.database.host" .) .Values.database.external.host }}
port: {{ default (include "core.database.port" .) .Values.database.external.port }}
{{- if .Values.database.external_replica }}
replica:
username: {{ .Values.database.external_replica.username | default "" }}
password: {{ .Values.database.external_replica.password | default "" }}
host: {{ .Values.database.external_replica.host | default "" }}
port: {{ .Values.database.external_replica.port | default "" }}
{{- end }}
name: model
version: {{ .Values.modelBackend.dbVersion }}
timezone: Etc/UTC
Expand Down
7 changes: 7 additions & 0 deletions charts/core/templates/pipeline-backend/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,13 @@ data:
password: {{ default (include "core.database.rawPassword" .) .Values.database.external.password }}
host: {{ default (include "core.database.host" .) .Values.database.external.host }}
port: {{ default (include "core.database.port" .) .Values.database.external.port }}
{{- if .Values.database.external_replica }}
replica:
username: {{ .Values.database.external_replica.username | default "" }}
password: {{ .Values.database.external_replica.password | default "" }}
host: {{ .Values.database.external_replica.host | default "" }}
port: {{ .Values.database.external_replica.port | default "" }}
{{- end }}
name: pipeline
version: {{ .Values.pipelineBackend.dbVersion }}
timezone: Etc/UTC
Expand Down

0 comments on commit bdf84a9

Please sign in to comment.