sources/ldap: made ldap_sync_single calls from ldap_sync_all asynchronous (#6862)

This commit is contained in:
Alissa Gerhard 2023-10-16 13:11:34 +02:00 committed by GitHub
parent 07b8c5bc7a
commit 00b2a773b4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -32,7 +32,7 @@ CACHE_KEY_PREFIX = "goauthentik.io/sources/ldap/page/"
def ldap_sync_all():
"""Sync all sources"""
for source in LDAPSource.objects.filter(enabled=True):
ldap_sync_single(source.pk)
ldap_sync_single.apply_async(args=[source.pk])
@CELERY_APP.task(