Compare commits

...

2 Commits

Author SHA1 Message Date
a6821995ca fix post init location 2024-06-14 21:23:48 -05:00
4291c3d18c add options for postgresql init 2024-06-14 21:17:45 -05:00
2 changed files with 11 additions and 5 deletions

View File

@@ -1,6 +1,6 @@
apiVersion: v2 apiVersion: v2
name: postgres-cluster name: postgres-cluster
version: 3.1.0 version: 3.3.0
description: Chart for cloudnative-pg cluster description: Chart for cloudnative-pg cluster
keywords: keywords:
- database - database
@@ -10,4 +10,4 @@ sources:
maintainers: maintainers:
- name: alexlebens - name: alexlebens
icon: https://avatars.githubusercontent.com/u/100373852?s=48&v=4 icon: https://avatars.githubusercontent.com/u/100373852?s=48&v=4
appVersion: v1.22.2 appVersion: v1.23.1

View File

@@ -21,6 +21,12 @@ bootstrap:
{{- printf "- %s" . | nindent 6 }} {{- printf "- %s" . | nindent 6 }}
{{- end }} {{- end }}
{{- end }} {{- end }}
postInitSQL:
{{- with .Values.cluster.initdb }}
{{- range .postInitSQL }}
{{- printf "- %s" . | nindent 6 }}
{{- end }}
{{- end }}
{{- else if eq .Values.mode "replica" }} {{- else if eq .Values.mode "replica" }}
initdb: initdb:
import: import:
@@ -32,7 +38,7 @@ bootstrap:
{{- with .Values.replica.importDatabases }} {{- with .Values.replica.importDatabases }}
{{- . | toYaml | nindent 8 }} {{- . | toYaml | nindent 8 }}
{{- end }} {{- end }}
{{- end }} {{- end }}
{{- if eq .Values.replica.importType "monolith" }} {{- if eq .Values.replica.importType "monolith" }}
roles: roles:
{{- with .Values.replica.importRoles }} {{- with .Values.replica.importRoles }}
@@ -43,7 +49,7 @@ bootstrap:
postImportApplicationSQL: postImportApplicationSQL:
{{- with .Values.replica.postImportApplicationSQL }} {{- with .Values.replica.postImportApplicationSQL }}
{{- . | toYaml | nindent 8 }} {{- . | toYaml | nindent 8 }}
{{- end }} {{- end }}
{{- end }} {{- end }}
source: source:
externalCluster: "{{ include "cluster.name" . }}-cluster" externalCluster: "{{ include "cluster.name" . }}-cluster"
@@ -51,7 +57,7 @@ externalClusters:
- name: "{{ include "cluster.name" . }}-cluster" - name: "{{ include "cluster.name" . }}-cluster"
{{- with .Values.replica.externalCluster }} {{- with .Values.replica.externalCluster }}
{{- . | toYaml | nindent 4 }} {{- . | toYaml | nindent 4 }}
{{- end }} {{- end }}
{{- else if eq .Values.mode "recovery" }} {{- else if eq .Values.mode "recovery" }}
recovery: recovery:
{{- with .Values.recovery.pitrTarget.time }} {{- with .Values.recovery.pitrTarget.time }}