Skip to content

Commit

Permalink
feat(cnpg-cluster): Add volume snapshot backup support
Browse files Browse the repository at this point in the history
  • Loading branch information
Tassatux committed Apr 25, 2024
1 parent f36246c commit acc0eca
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions charts/cnpg-cluster/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ The command removes all the Kubernetes components associated with the chart and
| backup.secretName | string | `nil` | Override secret name for the backup credentials |
| backup.serverName | string | `nil` | The server name on S3, the cluster name is used if this parameter is omitted |
| backup.tags | object | `{}` | |
| backup.volumeSnapshot | object | `{}` | The configuration for the execution of volume snapshot backups. See: https://cloudnative-pg.io/documentation/1.22/cloudnative-pg.v1/#postgresql-cnpg-io-v1-VolumeSnapshotConfiguration |
| backup.wal | object | `{}` | Configuration of the backup of the WAL stream See: https://cloudnative-pg.io/documentation/1.17/api_reference/#walbackupconfiguration |
| clusterExtraSpec | object | `{}` | Extra configuration for Cluster resource. See: https://cloudnative-pg.io/documentation/1.17/api_reference/#clusterspec |
| customServices | object | `{"any":{"annotations":{},"enabled":false,"externalIPs":[],"type":"ClusterIP"},"r":{"annotations":{},"enabled":false,"externalIPs":[],"type":"ClusterIP"},"ro":{"annotations":{},"enabled":false,"externalIPs":[],"type":"ClusterIP"},"rw":{"annotations":{},"enabled":false,"externalIPs":[],"type":"ClusterIP"}}` | Custom services to create |
Expand Down
4 changes: 4 additions & 0 deletions charts/cnpg-cluster/templates/cluster.cnpg.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,10 @@ spec:
{{- end }}
{{- else }}
{{- end }}
{{- with .Values.backup.volumeSnapshot }}
volumeSnapshot:
{{- toYaml . | nindent 6 }}
{{- end }}
{{- end }}

{{- with .Values.clusterExtraSpec }}
Expand Down
4 changes: 4 additions & 0 deletions charts/cnpg-cluster/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,10 @@ backup:
# storageSasToken:
# inheritFromAzureAD:

# -- (object) The configuration for the execution of volume snapshot backups.
# See: https://cloudnative-pg.io/documentation/1.22/cloudnative-pg.v1/#postgresql-cnpg-io-v1-VolumeSnapshotConfiguration
volumeSnapshot: {}

# -- Extra configuration for Cluster resource.
# See: https://cloudnative-pg.io/documentation/1.17/api_reference/#clusterspec
clusterExtraSpec: {}
Expand Down

0 comments on commit acc0eca

Please sign in to comment.