Skip to content

Instantly share code, notes, and snippets.

@tioxy
Created March 31, 2019 23:46
Show Gist options
  • Save tioxy/1323c380b600a1f886ad4d3d527e397e to your computer and use it in GitHub Desktop.
Save tioxy/1323c380b600a1f886ad4d3d527e397e to your computer and use it in GitHub Desktop.
Deploying Velero for a Kubernetes cluster hosted in GCP
# Deploying Velero for a Kubernetes cluster hosted in GCP
# For in depth details, check https://heptio.github.io/velero/master/gcp-config.html
export VELERO_FOLDER=/opt/velero
export BUCKET_NAME=k8s-cluster-velero # Use a different name
kubectl create secret generic cloud-credentials \
--namespace velero \
--from-file cloud=$VELERO_FOLDER/credentials-velero
sed -e "s/<YOUR_BUCKET>/${BUCKET_NAME}/g" \
-i $VELERO_FOLDER/config/gcp/05-backupstoragelocation.yaml
kubectl apply -f $VELERO_FOLDER/config/gcp/05-backupstoragelocation.yaml
kubectl apply -f $VELERO_FOLDER/config/gcp/06-volumesnapshotlocation.yaml
kubectl apply -f $VELERO_FOLDER/config/gcp/10-deployment.yaml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment