icicimov / kubernetes-bitwarden_rs

Kubernetes manifests for the bitwarden_rs project https://github.com/dani-garcia/bitwarden_rs.git
Apache License 2.0
49 stars 41 forks source link

Backups #4

Open vitobotta opened 5 years ago

vitobotta commented 5 years ago

Hi! I have a Docker installation of Bitwarden_rs that I want to migrate to Kubernetes. How would I go about implementing scheduled backups? I use Velero for everything, how could I integrate the two? Thanks!

LelandSindt commented 1 year ago

On the off chance that you are still looking... Here is how I implemented backups.. https://github.com/wizardlyEinstein/vault/blob/main/backup.yaml

lvnilesh commented 1 year ago

Thanks @LelandSindt. I looked through your backup.yaml I see that you tar the entire /data/ folder, encrypt it, and push encrypted backup to storage via a cron job but could not find how you generate that export.json from vaultwarden application.

I am interested in backing just my data that is exported via the application. Would you please advise? Thanks.

lvnilesh commented 1 year ago

Found a different method to use Bitwarden-cli to export the entire data

bw config server https://vault.example.com
bw login email@example.com --method 2

bw unlock

To unlock your vault, set your session key to the `BW_SESSION` environment variable. ex:

export BW_SESSION="token"

bw get password google.com
bw export --format json --output vaultwarden.json

Now I wonder what are the pros and cons of the two methods of backup.