Skip to content

ADR-0005: Velero backup for JupyterHub singleuser PVCs#278

Open
tylerpotts wants to merge 1 commit intomainfrom
adr/velero-user-pvc-backup
Open

ADR-0005: Velero backup for JupyterHub singleuser PVCs#278
tylerpotts wants to merge 1 commit intomainfrom
adr/velero-user-pvc-backup

Conversation

@tylerpotts
Copy link
Copy Markdown
Contributor

Summary

  • Adds ADR-0005 proposing Velero with helper pods for backing up and restoring JupyterHub user PVCs
  • Updates the ADR index in README.md

Context

JupyterHub user PVCs (claim-{username}) are the primary store of user work. There is currently no backup or recovery mechanism. This ADR evaluates three approaches and proposes Velero file-system backup with a helper-pod pattern.

The key insight from the POC: Velero's file-system backup (Kopia) requires a running pod to mount the volume, and Velero's restore injects data-download init containers only into pods it creates. Since JupyterHub user servers are ephemeral and spawned by KubeSpawner (not Velero), both backup and restore need lightweight helper pods to bridge the gap.

Options evaluated

  1. CSI volume snapshots - fastest, but requires snapshot controller + provider-specific VolumeSnapshotClass (not available everywhere)
  2. Velero + helper pods (proposed) - works on any storage backend, cloud-agnostic
  3. Direct rsync/rclone - reinvents backup orchestration, no ecosystem support

Validated by POC

Tested on k3s v1.34 / Hetzner Cloud with hcloud-volumes StorageClass:

  • Full backup/restore cycle with ~1.1 GB of user data
  • Confirmed that backup without helper pods captures PVC metadata but not file contents
  • Confirmed that restore without helper pods leaves volumes empty

POC implementation: https://github.com/openteams-ai/NIC-argocd-tyler-dev/pull/1
Tracking issue: nebari-dev/nebari-data-science-pack#49

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.

2 participants