frindaddy / mixd

Cocktail portfolio/repository for sharing drink recipes between friends
0 stars 0 forks source link

Multiple backups #33

Closed frindaddy closed 2 months ago

frindaddy commented 8 months ago

Currently, a single file is used as a backup, and it is overwritten every time the database is updated. This leaves us in a vulnerable position where if that single file is corrupted, or the entire database is accidentally deleted in a single POST, the backup file will be useless.

To remedy this, we should have multiple backups, each with a timestamp. The tricky part is limiting the number of backups to a reasonable number, say the 10 newest, else the backups folder will infinitely (albeit slowly) grow in size.