Velero gives you tools to back up and restore your Kubernetes cluster resources and persistent volumes. You can run Velero with a public cloud platform or on-premises.
Latest version of Velero
Velero's own documentation
-
Create and Change directory to
infrastructure/base/velero
-
Create
namespace.yaml
kubectl create namespace velero
- Create
helmrepository.yaml
flux create source helm vmware-tanzu \
--url=https://vmware-tanzu.github.io/helm-charts \
--interval=1h \
--export > helmrepository.yaml
- Create
helmrelease.yaml
flux create helmrelease velero \
--source=HelmRepository/vmware-tanzu \
--chart=velero \
--chart-version=">=5.2.0-0" \
--release-name=velero \
--target-namespace=velero \
--interval=1h \
--values=./values.yaml \
--export > helmrelease.yaml
- Create
kustomization.yaml
kustomize create --autodetect
- Commit your changes to Git
-
Configure the backup storage location - Velero Docs
velero install \
--provider aws \
--plugins velero/velero-plugin-for-aws:v1.8.2 \
--bucket $BUCKET \
--backup-location-config region=$REGION \
--snapshot-location-config region=$REGION \
--secret-file ./credentials-velero
velero schedule create <SCHEDULE_NAME> \
--schedule="@every 24h" \
--include-namespaces <NAMESPACES> \
--exclude-namespaces <NAMESPACES> \
--ttl 72h0m0s
If you wish to backup all namespaces, you can use the --all-namespaces
flag instead of --include-namespaces
and --exclude-namespaces
.
velero schedule create <SCHEDULE_NAME> \
--schedule="@every 24h" \
--all-namespaces \
--ttl 72h0m0s