1
0
mirror of https://github.com/funkypenguin/geek-cookbook/ synced 2025-12-13 01:36:23 +00:00
Files
geek-cookbook/docs/kubernetes/backup/csi-snapshots/snapshot-controller.md
David Young f22dd8eb50 Add authentik, tidy up recipe-footer
Signed-off-by: David Young <davidy@funkypenguin.co.nz>
2023-10-31 14:37:29 +13:00

2.9 KiB

title, description, values_yaml_url, helm_chart_version, helm_chart_name, helm_chart_repo_name, helm_chart_repo_url, helmrelease_name, helmrelease_namespace, kustomization_name, slug, status
title description values_yaml_url helm_chart_version helm_chart_name helm_chart_repo_name helm_chart_repo_url helmrelease_name helmrelease_namespace kustomization_name slug status
Support CSI VolumeSnapshots with snapshot-controller Add CSI VolumeSnapshot support with snapshot support https://github.com/piraeusdatastore/helm-charts/blob/main/charts/snapshot-controller/values.yaml 1.8.x snapshot-controller piraeus-charts https://piraeus.io/helm-charts/ snapshot-controller snapshot-controller snapshot-controller Snapshot Controller new

Add CSI VolumeSnapshot support with snapshot support

Before we deploy snapshot-controller to actually manage the snapshots we take, we need the validation webhook to make sure it's done "right".

{{ page.meta.slug }} requirements

!!! summary "Ingredients"

Already deployed:

* [x] A [Kubernetes cluster](/kubernetes/cluster/)
* [x] [Flux deployment process](/kubernetes/deployment/flux/) bootstrapped
* [x] [snapshot-validation-webhook](/kubernetes/backup/csi-snapshots/snapshot-validation-webhook/) deployed

{% include 'kubernetes-flux-namespace.md' %} {% include 'kubernetes-flux-kustomization.md' %} {% include 'kubernetes-flux-helmrelease.md' %}

Configure for rook-ceph

Under the HelmRelease values which you pasted from upstream, you'll note a section for volumeSnapshotClasses. By default, this is populated with commented out examples. To configure snapshot-controller to work with rook-ceph, replace these commented values as illustrated below:

  values:
    # extra content from upstream
    volumeSnapshotClasses:
    - name: csi-rbdplugin-snapclass
      driver: rook-ceph.rbd.csi.ceph.com # driver:namespace:operator
      labels:
        velero.io/csi-volumesnapshot-class: "true"
      parameters:
        # Specify a string that identifies your cluster. Ceph CSI supports any
        # unique string. When Ceph CSI is deployed by Rook use the Rook namespace,
        # for example "rook-ceph".
        clusterID: rook-ceph # namespace:cluster
        csi.storage.k8s.io/snapshotter-secret-name: rook-csi-rbd-provisioner
        csi.storage.k8s.io/snapshotter-secret-namespace: rook-ceph # namespace:cluster
      deletionPolicy: Delete # docs suggest this may need to be set to "Retain" for restoring

{% include 'kubernetes-flux-check.md' %}

Summary

What have we achieved? We've got snapshot-controller running, and ready to manage VolumeSnapshots on behalf of Velero, for handy in-cluster volume backups!

!!! summary "Summary" Created:

* [X] snapshot-controller running and ready to snap :camera: !

Next:

* [ ] Configure [Velero](/kubernetes/backup/velero/) with a VolumeSnapshotLocation, so that volume snapshots can be made as part of a BackupSchedule!

{% include 'recipe-footer.md' %}