How do you back up Jenkins running on Kubernetes?
IntermediateConceptBackups, HA, upgrades & performance
Answer
Snapshot the JENKINS_HOME PersistentVolume with VolumeSnapshots (CSI) or Velero on a schedule, and/or run a CronJob that tars the important paths (excluding workspaces) and uploads to S3 with versioning and object lock. Practise restores: restore the snapshot into a new PVC, start a controller from the same image and JCasC, check credentials decrypt and build history appears.
More on Backups, HA, upgrades & performance
What do you back up in Jenkins and what do you exclude?IntermediateDoes Jenkins support active-active high availability?AdvancedHow do you plan a Jenkins LTS upgrade?IntermediateWhat does "Manage Old Data" mean after an upgrade?BeginnerHow do you size and tune the controller JVM?AdvancedWhat are the most common causes of a slow Jenkins controller?Intermediate