From 9a90e0391a32ace46fb431b03dfbe52f40393667 Mon Sep 17 00:00:00 2001 From: Radek Czajka Date: Tue, 30 Mar 2021 13:57:18 +0200 Subject: [PATCH] OIDC support. --- requirements.txt | 1 + src/cas/settings.py | 3 +++ src/cas/urls.py | 2 ++ 3 files changed, 6 insertions(+) diff --git a/requirements.txt b/requirements.txt index 55046b4..d5ed1f4 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,4 +1,5 @@ Django==3.1.7 django-gravatar2==1.4.4 +django-oidc-provider2==0.8.3 -e git+https://github.com/fnp/django-cas-provider.git@53585f7615b3a647d1badda1a2ebd7f5ec81f607#egg=django-cas-provider diff --git a/src/cas/settings.py b/src/cas/settings.py index 4101776..47afd45 100644 --- a/src/cas/settings.py +++ b/src/cas/settings.py @@ -37,6 +37,8 @@ SITE_ID = 1 # to load the internationalization machinery. USE_I18N = True +USE_TZ = True + # Absolute path to the directory that holds media. # Example: "/home/media/media.lawrence.com/" MEDIA_ROOT = path.join(PROJECT_ROOT, '../../media/') @@ -90,6 +92,7 @@ INSTALLED_APPS = ( 'cas_provider', 'django_gravatar', + 'oidc_provider', 'django.contrib.auth', 'django.contrib.contenttypes', diff --git a/src/cas/urls.py b/src/cas/urls.py index 71a3827..ce01eb0 100644 --- a/src/cas/urls.py +++ b/src/cas/urls.py @@ -13,6 +13,8 @@ urlpatterns = [ # django-cas-provider path('cas/', include('cas_provider.urls')), + path('openid/', include('oidc_provider.urls', namespace='oidc_provider')), + # Admin panel path('admin/doc/', include('django.contrib.admindocs.urls')), path('admin/', admin.site.urls), -- 2.20.1