Skip to content

Conversation

@doulikecookiedough
Copy link
Contributor

@doulikecookiedough doulikecookiedough commented Nov 7, 2025

Hi @artntek - this was blocking me from testing so I made some changes locally to test - it seems to work so I committed the changes and opened a PR. Can you please take a look and let me know if this PR resolves issue?

Summary of Changes:

  • Added backup section with documentation in values.yaml
    • By default, we are going to use volumeSnapshots as the backup method with the csi-cephfsplugin-snapclass class
  • Updated template pg_cluster.yaml with section to pick up user specified backup values
  • I've tested these changes locally and it appears to be working:
    $ kubectl apply -f '/Users/doumok/Code/vegbank2/helm/backup/scheduled-backup.yaml' -n vegbank-dev --context=dev-k8s
    scheduledbackup.postgresql.cnpg.io/vegbankdb-scheduled-backup created
    
    $ kubectl get scheduledbackup -n vegbank-dev --context=dev-k8s
    NAME                         AGE   CLUSTER          LAST BACKUP
    vegbankdb-scheduled-backup   57s   vegbankdb-cnpg   57s
    
    $ kubectl get backups
    NAME                                        AGE   CLUSTER          METHOD           PHASE       ERROR
    vegbankdb-scheduled-backup-20251107221536   12s   vegbankdb-cnpg   volumeSnapshot   completed 

Copy link
Collaborator

@artntek artntek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome - thank you for doing this!

@doulikecookiedough doulikecookiedough merged commit f3c0fe3 into main Nov 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add CNPG Backup and Restore with volume snapshots

3 participants