mirror of
https://github.com/bitnami/charts.git
synced 2026-04-06 09:17:08 +08:00
[bitnami/postgresql] Allow customizing primary persistence volume/claim (#24625)
Signed-off-by: Matthew McMillan <3170853+UnsolvedCypher@users.noreply.github.com>
This commit is contained in:
@@ -35,4 +35,4 @@ maintainers:
|
||||
name: postgresql
|
||||
sources:
|
||||
- https://github.com/bitnami/charts/tree/main/bitnami/postgresql
|
||||
version: 15.1.4
|
||||
version: 15.2.0
|
||||
|
||||
@@ -478,6 +478,7 @@ If you already have data in it, you will fail to sync to standby nodes for all c
|
||||
| `primary.service.sessionAffinityConfig` | Additional settings for the sessionAffinity | `{}` |
|
||||
| `primary.service.headless.annotations` | Additional custom annotations for headless PostgreSQL primary service | `{}` |
|
||||
| `primary.persistence.enabled` | Enable PostgreSQL Primary data persistence using PVC | `true` |
|
||||
| `primary.persistence.volumeName` | Name to assign the volume | `data` |
|
||||
| `primary.persistence.existingClaim` | Name of an existing PVC to use | `""` |
|
||||
| `primary.persistence.mountPath` | The path the volume will be mounted at | `/bitnami/postgresql` |
|
||||
| `primary.persistence.subPath` | The subdirectory of the volume to mount to | `""` |
|
||||
|
||||
@@ -162,7 +162,7 @@ spec:
|
||||
- name: empty-dir
|
||||
mountPath: /tmp
|
||||
subPath: tmp-dir
|
||||
- name: data
|
||||
- name: {{ .Values.primary.persistence.volumeName }}
|
||||
mountPath: {{ .Values.primary.persistence.mountPath }}
|
||||
{{- if .Values.primary.persistence.subPath }}
|
||||
subPath: {{ .Values.primary.persistence.subPath }}
|
||||
@@ -495,7 +495,7 @@ spec:
|
||||
mountPath: /dev/shm
|
||||
{{- end }}
|
||||
{{- if .Values.primary.persistence.enabled }}
|
||||
- name: data
|
||||
- name: {{ .Values.primary.persistence.volumeName }}
|
||||
mountPath: {{ .Values.primary.persistence.mountPath }}
|
||||
{{- if .Values.primary.persistence.subPath }}
|
||||
subPath: {{ .Values.primary.persistence.subPath }}
|
||||
@@ -650,11 +650,11 @@ spec:
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if and .Values.primary.persistence.enabled .Values.primary.persistence.existingClaim }}
|
||||
- name: data
|
||||
- name: {{ .Values.primary.persistence.volumeName }}
|
||||
persistentVolumeClaim:
|
||||
claimName: {{ tpl .Values.primary.persistence.existingClaim $ }}
|
||||
{{- else if not .Values.primary.persistence.enabled }}
|
||||
- name: data
|
||||
- name: {{ .Values.primary.persistence.volumeName }}
|
||||
emptyDir: {}
|
||||
{{- else }}
|
||||
{{- if .Values.primary.persistentVolumeClaimRetentionPolicy.enabled }}
|
||||
@@ -666,7 +666,7 @@ spec:
|
||||
- apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: data
|
||||
name: {{ .Values.primary.persistence.volumeName }}
|
||||
{{- if .Values.primary.persistence.annotations }}
|
||||
annotations: {{- include "common.tplvalues.render" (dict "value" .Values.primary.persistence.annotations "context" $) | nindent 10 }}
|
||||
{{- end }}
|
||||
|
||||
@@ -738,6 +738,9 @@ primary:
|
||||
## @param primary.persistence.enabled Enable PostgreSQL Primary data persistence using PVC
|
||||
##
|
||||
enabled: true
|
||||
## @param primary.persistence.volumeName Name to assign the volume
|
||||
##
|
||||
volumeName: "data"
|
||||
## @param primary.persistence.existingClaim Name of an existing PVC to use
|
||||
##
|
||||
existingClaim: ""
|
||||
|
||||
Reference in New Issue
Block a user