*: decrease frequency of background tasks, smear tasks based on name and fqdn

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>

#2159
This commit is contained in:
Jens Langhammer
2022-04-20 18:42:56 +02:00
parent 1328c3e62c
commit 1a1434bfda
9 changed files with 37 additions and 17 deletions

View File

@ -337,17 +337,12 @@ CELERY_WORKER_MAX_TASKS_PER_CHILD = 50
CELERY_BEAT_SCHEDULE = {
"clean_expired_models": {
"task": "authentik.core.tasks.clean_expired_models",
"schedule": crontab(minute="*/5"),
"options": {"queue": "authentik_scheduled"},
},
"db_backup": {
"task": "authentik.core.tasks.backup_database",
"schedule": crontab(hour="*/24", minute=0),
"schedule": crontab(minute="2-59/5"),
"options": {"queue": "authentik_scheduled"},
},
"user_cleanup": {
"task": "authentik.core.tasks.clean_temporary_users",
"schedule": crontab(minute="*/5"),
"schedule": crontab(minute="9-59/5"),
"options": {"queue": "authentik_scheduled"},
},
}