diff --git a/kubernetes/common/templates/volsync/b2.yaml b/kubernetes/common/templates/volsync/b2.yaml index 159e471..9f46c2a 100644 --- a/kubernetes/common/templates/volsync/b2.yaml +++ b/kubernetes/common/templates/volsync/b2.yaml @@ -11,7 +11,7 @@ spec: copyMethod: "${VOLSYNC_COPYMETHOD:-Snapshot}" pruneIntervalDays: 7 repository: "${APP}-volsync-b2-secret" - volumeSnapshotClassName: "${VOLSYNC_SNAPSHOTCLASS:-longhorn}" + volumeSnapshotClassName: "${VOLSYNC_SNAPSHOTCLASS:-longhorn-backup}" cacheCapacity: "${VOLSYNC_CACHE_CAPACITY:-4Gi}" cacheStorageClassName: "${VOLSYNC_CACHE_SNAPSHOTCLASS:-mainpool-hostpath}" cacheAccessModes: ["${VOLSYNC_CACHE_ACCESSMODES:-ReadWriteOnce}"] diff --git a/kubernetes/common/templates/volsync/minio.yaml b/kubernetes/common/templates/volsync/minio.yaml index 51d5440..eb53d5f 100644 --- a/kubernetes/common/templates/volsync/minio.yaml +++ b/kubernetes/common/templates/volsync/minio.yaml @@ -12,7 +12,7 @@ spec: copyMethod: "${VOLSYNC_COPYMETHOD:-Snapshot}" pruneIntervalDays: 7 repository: "${APP}-volsync-secret" - volumeSnapshotClassName: "${VOLSYNC_SNAPSHOTCLASS:-longhorn}" + volumeSnapshotClassName: "${VOLSYNC_SNAPSHOTCLASS:-longhorn-backup}" cacheCapacity: "${VOLSYNC_CACHE_CAPACITY:-4Gi}" cacheStorageClassName: "${VOLSYNC_CACHE_SNAPSHOTCLASS:-mainpool-hostpath}" cacheAccessModes: ["${VOLSYNC_CACHE_ACCESSMODES:-ReadWriteOnce}"] @@ -38,7 +38,7 @@ spec: restic: repository: "${APP}-volsync-secret" copyMethod: Snapshot # must be Snapshot - volumeSnapshotClassName: "${VOLSYNC_SNAPSHOTCLASS:-longhorn}" + volumeSnapshotClassName: "${VOLSYNC_SNAPSHOTCLASS:-longhorn-backup}" cacheStorageClassName: "${VOLSYNC_CACHE_SNAPSHOTCLASS:-mainpool-hostpath}" cacheAccessModes: ["${VOLSYNC_CACHE_ACCESSMODES:-ReadWriteOnce}"] cacheCapacity: "${VOLSYNC_CACHE_CAPACITY:-8Gi}" diff --git a/kubernetes/main/core/longhorn/kustomization.yaml b/kubernetes/main/core/longhorn/kustomization.yaml index 7be259d..6efbdcb 100644 --- a/kubernetes/main/core/longhorn/kustomization.yaml +++ b/kubernetes/main/core/longhorn/kustomization.yaml @@ -5,4 +5,5 @@ resources: - ./helm-repository.yaml - ./helm-release.yaml - ./alerts.yaml -- ./service-monitor.yaml \ No newline at end of file +- ./service-monitor.yaml +- ./snapshot-class-bak.yaml \ No newline at end of file diff --git a/kubernetes/main/core/longhorn/snapshot-class-bak.yaml b/kubernetes/main/core/longhorn/snapshot-class-bak.yaml new file mode 100644 index 0000000..0004e25 --- /dev/null +++ b/kubernetes/main/core/longhorn/snapshot-class-bak.yaml @@ -0,0 +1,9 @@ +# yaml-language-server: $schema=https://kubernetes-schemas.pages.dev/snapshot.storage.k8s.io/volumesnapshotclass_v1.json +kind: VolumeSnapshotClass +apiVersion: snapshot.storage.k8s.io/v1 +metadata: + name: longhorn-backup +driver: driver.longhorn.io +deletionPolicy: Delete +parameters: + type: bak \ No newline at end of file