-
Notifications
You must be signed in to change notification settings - Fork 4
/
urls.py
32 lines (27 loc) · 1.19 KB
/
urls.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
from django.conf.urls.defaults import *
from django.conf import settings
from django.views.generic.simple import direct_to_template
# Uncomment the next two lines to enable the admin:
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
(r'^$', 'dash.cluster.views.dash'),
(r'^accounts/login/$', 'django.contrib.auth.views.login'),
(r'^accounts/logout/$', 'django.contrib.auth.views.logout', {'next_page': '/'}),
(r'^cluster/', include('dash.cluster.urls')),
(r'^admin/', include(admin.site.urls)),
(r'^support/$', direct_to_template, {
'template': 'support.html'
})
)
if settings.DEBUG:
urlpatterns += patterns('',
(r'^js/(?P<path>.*)$', 'django.views.static.serve',
{'document_root': settings.STATIC_DOC_ROOT + '/js/' }),
(r'^css/(?P<path>.*)$', 'django.views.static.serve',
{'document_root': settings.STATIC_DOC_ROOT + '/css/' }),
(r'^img/(?P<path>.*)$', 'django.views.static.serve',
{'document_root': settings.STATIC_DOC_ROOT + '/img/' }),
(r'^movie/(?P<path>.*)$', 'django.views.static.serve',
{'document_root': settings.STATIC_DOC_ROOT + '/movie/' }),
)