summaryrefslogtreecommitdiffstats
path: root/it
diff options
context:
space:
mode:
Diffstat (limited to 'it')
-rw-r--r--it/settings.py9
-rw-r--r--it/urls.py7
2 files changed, 16 insertions, 0 deletions
diff --git a/it/settings.py b/it/settings.py
index 5b348d7..3fe96a1 100644
--- a/it/settings.py
+++ b/it/settings.py
@@ -47,6 +47,7 @@ MIDDLEWARE_CLASSES = (
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
+ 'apps.it.login_required_middleware.LoginRequiredMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
)
@@ -89,3 +90,11 @@ TEMPLATE_LOADERS = (
)
MEDIA_ROOT = os.path.join(BASE_DIR, 'uploads')
+
+EXEMPT_URLS = []
+
+LOGIN_URL = '/login/'
+LOGOUT_URL = '/logout/'
+
+# URLs that should work without logging in
+LOGIN_EXEMPT_URLS = [LOGIN_URL.lstrip('/')]
diff --git a/it/urls.py b/it/urls.py
index 991acf5..ac880e7 100644
--- a/it/urls.py
+++ b/it/urls.py
@@ -25,4 +25,11 @@ urlpatterns = patterns('apps.it',
url(r'^tags/$', 'views.tags', name='tags'),
url(r'^tags/(\d+)/delete/$', 'views.delete_tag', name='delete_tag'),
+
+ url(r'^users/$', 'views.users', name='users'),
+
+ url(r'^docs/$', 'views.docs', name='docs'),
+
+ url(r'^login/$', 'views.login', name='login'),
+ url(r'^logout/$', 'views.logout', name='logout'),
)