All Projects → vmware-tanzu → velero-plugin-for-csi

vmware-tanzu / velero-plugin-for-csi

Licence: Apache-2.0 license
Velero plugins for integrating with CSI snapshot API

Programming Languages

go
31211 projects - #10 most used programming language
shell
77523 projects
Makefile
30231 projects
Dockerfile
14818 projects

Projects that are alternatives of or similar to velero-plugin-for-csi

velero-plugin-for-aws
Plugins to support Velero on AWS
Stars: ✭ 115 (+101.75%)
Mutual labels:  velero, velero-plugin
velero-plugin-example
Example project for plugins for Velero, a Kubernetes disaster recovery utility
Stars: ✭ 45 (-21.05%)
Mutual labels:  velero, velero-plugin
Velero
Backup and migrate Kubernetes applications and their persistent volumes
Stars: ✭ 5,864 (+10187.72%)
Mutual labels:  velero
k3s-gitops
GitOps principles to define kubernetes cluster state via code
Stars: ✭ 103 (+80.7%)
Mutual labels:  velero

Build Status

Velero CSI plugins

This repository contains Velero plugins for snapshotting CSI backed PVCs using the CSI beta snapshot APIs.

CSI plugin reaches GA for AWS and Azure environments as of the Velero 1.9 release. It should also work for those environments in which CSI plugin provides durable snapshot (please check WARNING section for more details), but Velero team doesn't have enough resources to verify, so please do enough tests before using CSI plugin in some environments. For those environments that don't have durable snapshot capability, CSI plugin is still in beta state. After Velero's data mover function is ready (hopefully in Velero v1.10), CSI plugin will GA for those environments too.

For a list of prerequisites and installation instructions, please refer to our documentation here.

WARNING

CSI Snapshots are a standard Kubernetes mechanism for taking snapshots. The actual implementation of snapshots varies by storage vendor. For disaster recovery, snapshots must be stored in a durable store, such as an S3 bucket, tape library, etc. and not just on the primary storage. If the snapshot is only stored on the primary storage and the storage is corrupted or destroyed the backup will be lost.

CSI snapshots on AWS EBS, Azure managed disks and Google Cloud Persistent Disk are durable and can be safely used for backup.

For all other storage systems, please check with your storage vendor. If your storage vendor doesn't support durable snapshot storage you may want to consider Velero's Restic Integration

Compatibility

Below is a listing of plugin versions and respective Velero versions that are compatible.

Plugin Version Velero Version
v0.3.0 v1.9.x
v0.2.0 v1.7.x, v1.8.x
v0.1.2 v1.5.x, v1.6.x
v0.1.1 v1.4.x

Filing issues

If you would like to file a GitHub issue for the plugin, please open the issue on the core Velero repo

Kinds of Plugins Included

PVCBackupItemAction

A plugin of type BackupItemAction that backs up PersistentVolumeClaims which are backed by CSI volumes.

This plugin will create a CSI VolumeSnapshot which in turn triggers the CSI driver to perform the snapshot operation on the volume.

VolumeSnapshotBackupItemAction

A plugin of type BackupItemAction that backs up volumesnapshots.snapshot.storage.k8s.io.

When invoked, this plugin will capture information about the underlying volumesnapshotcontent.snapshot.storage.k8s.io in the annotations of the volumesnapshots being backed up. This plugin will also return the underlying volumesnapshotcontent.snapshot.storage.k8s.io and the associated snapshot.storage.k8s.io.volumesnapshotclasses as additional resources to be backed up.

VolumeSnapshotContentBackupItemAction

A plugin of type BackupItemAction that backs up volumesnapshotcontent.snapshot.storage.k8s.io.

This plugin will look for snapshot delete operation secrets from the annotations on the VolumeSnapshotContent object being backed up.

VolumeSnapshotClassBackupItemAction

A plugin of type BackupItemAction that backs up snapshot.storage.k8s.io.volumesnapshotclasses.

This plugin will look for snapshot list operation secret from the annotations on the VolumeSnapshotClass object being backed up.

PVCRestoreItemAction

A plugin of type RestoreItemAction that restores PersistentVolumeClaims which were backed up by PVCBackupItemAction.

This plugin will modify the spec of the PersistentVolumeClaim being restored to use the VolumeSnapshot, created during backup, as the data source ensuring that the newly provisioned volume, to satisfy this claim, may be pre-populated using the VolumeSnapshot.

VolumeSnapshotRestoreItemAction

A plugin of type RestoreItemAction that restores volumesnapshots.snapshot.storage.k8s.io.

This plugin will use the annotations, added during backup, to create a volumesnapshotcontent.snapshot.storage.k8s.io and statically bind it to the VolumeSnapshot object being restored. The plugin will also set the necessary annotations if the original VolumeSnapshotContent had snapshot deletion secrets associated with it.

VolumeSnapshotClassRestoreItemAction

A plugin of type RestoreItemAction that restores snapshot.storage.k8s.io.volumesnapshotclasses.

This plugin will use the annotations on the object being restored to return, as additional items, any snapshot lister secret that is associated with the VolumeSnapshotClass.

Building the plugins

Official images of the plugin are available on Velero DockerHub.

For development and testing, the plugin images may be built by running the below command

$ IMAGE=<YOUR_REGISTRY>/velero-plugin-for-csi:<YOUR_TAG> make container

Known shortcomings

We are tracking known limitations with the plugins here

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].