grav
grav copied to clipboard
Problem with Cron Backups via Admin Panel: Resulting in Backups every minute
After I added Backup profiles with automated job execution enabled, I got an enormous number of backups today.
Description
Last week, I added automated backups to my existing backup profiles. I did this on my production server directly, since I wanted to see if it worked over the weekend since I had to do some editing to cron execution on the server (managed).
My two backup profiles:
- data backup (
/user
dir without plugins/ themes), set to 'Every day at 00' - system backup (complete grav backup (default), set to 'Every week on Monday at 00'
This morning I was a bit confused since I had more than 100 backups. After checking the user/config/backups.yaml
file, I noticed that there was a misconfiguration:
- 'Every day at 00' matches
* 0 * * *
in Grav, but should be0 0 * * *
- 'Every week on Monday at 00' matches
* 0 * * 1
in Grav but should be0 0 * * 1
Because of that, Grav did a backup every day at 00:00 AND every minute past that hour, resulting in 60 backups per day instead of one.
Resolution
Please fix this issue by adding a minute field or replace the cron field with a text field like in the scheduler. I'd prefer the text field, although I really like how simple the cron field is for not experienced users.
But I could do some fancy stuff like 0 */6 * * *
which isn't possible with the cron field and it will render as an error in the admin panel.