mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2026-01-15 00:12:35 +08:00
- Create archivebox/config/ldap.py with LDAPConfig class - Create archivebox/ldap/ Django app with custom auth backend - Update core/settings.py to conditionally load LDAP when enabled - Add LDAP_CREATE_SUPERUSER support to auto-grant superuser privileges - Add comprehensive tests in test_auth_ldap.py (no mocks, no skips) - LDAP only activates if django-auth-ldap is installed and LDAP_ENABLED=True - Helpful error messages when LDAP libraries are missing or config is incomplete Fixes #1664 Co-authored-by: Nick Sweeting <pirate@users.noreply.github.com>
14 lines
336 B
Python
14 lines
336 B
Python
"""Django app configuration for LDAP authentication."""
|
|
|
|
__package__ = "archivebox.ldap"
|
|
|
|
from django.apps import AppConfig
|
|
|
|
|
|
class LDAPConfig(AppConfig):
|
|
"""Django app config for LDAP authentication."""
|
|
|
|
default_auto_field = 'django.db.models.BigAutoField'
|
|
name = 'archivebox.ldap'
|
|
verbose_name = 'LDAP Authentication'
|