Implementation de sso
This commit is contained in:
47
SIRH/urls.py
47
SIRH/urls.py
@@ -16,32 +16,29 @@ Including another URLconf
|
||||
"""
|
||||
from django.contrib import admin
|
||||
from django.urls import include, path
|
||||
from django.conf.urls.static import static
|
||||
# from django.conf.urls.static import static
|
||||
from django.conf import settings
|
||||
# from simple_sso.sso_server.server import Server
|
||||
|
||||
from . import views
|
||||
from .sso import SIRHClient
|
||||
|
||||
# server_sso = Server()
|
||||
client_sirh = SIRHClient(
|
||||
settings.SSO_SERVER,
|
||||
settings.SSO_PUBLIC_KEY,
|
||||
settings.SSO_PRIVATE_KEY
|
||||
)
|
||||
|
||||
urlpatterns = [
|
||||
urlpatterns = [
|
||||
# path('login/',
|
||||
# views.login_view,
|
||||
# name='login'
|
||||
# ),
|
||||
# path(
|
||||
# 'deconnexion/',
|
||||
# views.deconnexion_view,
|
||||
# name='deconnexion'
|
||||
# ),
|
||||
path(
|
||||
'',
|
||||
views.login_view,
|
||||
name='index'
|
||||
),
|
||||
|
||||
path('login/',
|
||||
views.login_view,
|
||||
name='login'
|
||||
),
|
||||
path(
|
||||
'deconnexion/',
|
||||
views.deconnexion_view,
|
||||
name='deconnexion'
|
||||
),
|
||||
path(
|
||||
'employé/',
|
||||
include("gestion_employe.urls")
|
||||
),
|
||||
path(
|
||||
@@ -59,9 +56,7 @@ urlpatterns = [
|
||||
path(
|
||||
'admin/',
|
||||
admin.site.urls
|
||||
),
|
||||
# path(
|
||||
# 'sso',
|
||||
# include(server_sso.get_urls())
|
||||
# )
|
||||
] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
|
||||
),
|
||||
path("client/", include(client_sirh.get_urls())),
|
||||
]
|
||||
# + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
|
||||
Reference in New Issue
Block a user