christianwgd / django_restic_gui

A GUI web application for restic backup
MIT License
8 stars 2 forks source link

Populating charts for remote Restic repos #13

Open morlandi opened 2 years ago

morlandi commented 2 years ago

@christianwgd, RepositoryChart() seems a very good place for quickly check (visually) if backups are proceeding smoothly as expected. For me, this is the very first reason to have a GUI for Restic.

I noticed the log_size management command and was thinking about the possibility to collect data from remote repos with the stats Restic command, which gives the following result:

scanning...
Stats in restore-size mode:
Snapshots processed:   51
   Total File Count:   16253589
         Total Size:   45.928 GiB

Apart from the total size, which you're already collecting for local repos, both files count and snapshots count are interesting, and could be conveniently added to RepoSize model

Or maybe I should rather try rest-server and attach it to Prometheus

What do you think ?

christianwgd commented 2 years ago

Hi morlandi,

half way through I’ve detected the rest server, but didn’t change at that time. I gave priority to the MVP. Sure, give it a try and let’s see if we can change to that.

As soon I have a little time, I will subclass the json field to „EncryptedJSONField“.

Thanks for your effort, Christian

Am 17.06.2022 um 19:34 schrieb morlandi @.***>:

@christianwgd https://github.com/christianwgd, RepositoryChart() seems a very good place for quickly check (visually) if backups are proceeding smoothly as expected. For me, this is the very first reason to have a GUI for Restic.

I noticed the log_size management command and was thinking about the possibility to collect data from remote repos with the stats Restic command, which gives the following result:

scanning... Stats in restore-size mode: Snapshots processed: 51 Total File Count: 16253589 Total Size: 45.928 GiB Apart from the total size, which you're already collecting for local repos, both files count and snapshots count are interesting, and could be conveniently added to RepoSize model

Or maybe I should rather try rest-server and attach it to Prometheus

What do you think ?

— Reply to this email directly, view it on GitHub https://github.com/christianwgd/django_restic_gui/issues/13, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACG2A36N2NRDFAH3YLYMYH3VPSZMFANCNFSM5ZC6L76A. You are receiving this because you were mentioned.

morlandi commented 2 years ago

Hi Christian, sooner or later I will likely check the rest server, but for now I'm quite happy with my simple setup: I have a few restic repos on a storage box c/o Hetzner, and collect backups from different remote servers; each server has access to the storage box via SSH with it's own private key and uses restic commands via SFTP. That's what I expect from a backup strategy: to be simple, secure and reliable.

django_restic_gui is nice and simple; I just miss an overall view with a single summary chart for all repos; let me do some experiments and I'll be back with a new PR on this.

The restic "stats" command is rather slow given my actual configuration .. but who cares ? I'll collect new data in the background, once per day, via cron.

morlandi commented 1 year ago

Hi Christian, first of all I wish you an Happy New Year 🍾

I needed to encrypt the JSONFields in another project, and for this reason I created a fork of the original project:

https://github.com/morlandi/django-encrypted-json-fields

since the maintener at that moment was not available to manage my PR on the original, and the copy available on github was out of date.

Maybe in the future we could evaluate whether or not it is worth using it here too ...

christianwgd commented 1 year ago

Hey, same to you! Nice work, I just included your lib here and seems to work fine.