From 0a9b0f22b8fbda170375bfc2cc991936d5da8a91 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20Gruszczy=C5=84ski?= Date: Sun, 23 Feb 2025 23:19:33 +0100 Subject: [PATCH] fix cron on start --- app.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app.py b/app.py index aa29c2b..8a96505 100644 --- a/app.py +++ b/app.py @@ -608,9 +608,9 @@ scheduler = BackgroundScheduler() # 2) Auto-backup (default co 1 dzień) # Dodajemy z unikalnymi ID, co ułatwia re-schedulowanie -#scheduler.add_job(func=cleanup_old_backups, trigger='interval', days=1, id="cleanup_job") -#scheduler.add_job(func=scheduled_auto_backup, trigger='interval', days=1, id="auto_backup_job") -#scheduler.start() +scheduler.add_job(func=cleanup_old_backups, trigger='interval', days=1, id="cleanup_job") +scheduler.add_job(func=scheduled_auto_backup, trigger='interval', days=1, id="auto_backup_job") +scheduler.start() # Sprzątanie przy zamykaniu atexit.register(lambda: scheduler.shutdown())