From bc2b33b35d0b5633c3f241b347fb62c330b5da63 Mon Sep 17 00:00:00 2001 From: JensDiemer Date: Sat, 12 Dec 2020 20:35:08 +0100 Subject: [PATCH] remove unused conf file --- conf/ynh_sso_ldap_backend.py | 17 ----------------- scripts/install | 1 - scripts/upgrade | 1 - 3 files changed, 19 deletions(-) delete mode 100644 conf/ynh_sso_ldap_backend.py diff --git a/conf/ynh_sso_ldap_backend.py b/conf/ynh_sso_ldap_backend.py deleted file mode 100644 index baaea9b..0000000 --- a/conf/ynh_sso_ldap_backend.py +++ /dev/null @@ -1,17 +0,0 @@ -from django_auth_ldap.backend import LDAPBackend -from inventory.permissions import get_or_create_normal_user_group - - -class Django-For-RunnersYunohostLdapBackend(LDAPBackend): - def get_or_build_user(self, username, ldap_user): - user, built = super().get_or_build_user(username, ldap_user) - - if built: - user.is_staff = True - user.is_superuser = False - user.save() - - django-for-runners_user_group = get_or_create_normal_user_group()[0] - user.groups.set([django-for-runners_user_group]) - - return user, built diff --git a/scripts/install b/scripts/install index 233c626..7769f04 100755 --- a/scripts/install +++ b/scripts/install @@ -157,7 +157,6 @@ ynh_app_setting_set --app="$app" --key=redis_db --value="$redis_db" touch "$final_path/local_settings.py" -cp "../conf/ynh_sso_ldap_backend.py" "$final_path/ynh_sso_ldap_backend.py" cp "../conf/ynh_urls.py" "$final_path/ynh_urls.py" #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index 7f9ab31..a5d053b 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -147,7 +147,6 @@ ynh_store_file_checksum --file="$settings" touch "$final_path/local_settings.py" -cp "../conf/ynh_sso_ldap_backend.py" "$final_path/ynh_sso_ldap_backend.py" cp "../conf/ynh_urls.py" "$final_path/ynh_urls.py" #=================================================