kale icon indicating copy to clipboard operation
kale copied to clipboard

(Backend): Add ability to create a snapshot of a pod

Open davidspek opened this issue 3 years ago • 2 comments

Part of https://github.com/kubeflow-kale/kale/pull/217/files

This PR adds the ability to snapshot all the volumes connected to a pod, along with writing the container images of that pod to the snapshot metadata. Note, at the moment the snapshot name is pod-snapshot- + pvc_name. This means snapshotting a pod twice will result in an error as the snapshot with that name already exists. This will need to be solved with a UUID of some sorts, I was hoping to find one that is useful/meaningful for other methods of identification as well, so I am open to suggestions.

davidspek avatar Feb 01 '21 18:02 davidspek

@StefanoFioravanzo I believe this PR is ready for merging

davidspek avatar Feb 16 '21 13:02 davidspek

@StefanoFioravanzo I have added a small function to generate 8 character long UUID's to ensure snapshot names are unique and to be able to have multiple "versions" of snapshots for a pod.

davidspek avatar Feb 17 '21 10:02 davidspek