Merge remote-tracking branch 'origin/develop' into develop
[ganeti_webmgr.git] / urls.py
blobed17e5b45453eeea68a0e16bef965851ef60562a
1 # Copyright (C) 2010 Oregon State University et al.
2 # Copyright (C) 2010 Greek Research and Technology Network
4 # This program is free software; you can redistribute it and/or
5 # modify it under the terms of the GNU General Public License
6 # as published by the Free Software Foundation; either version 2
7 # of the License, or (at your option) any later version.
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 # GNU General Public License for more details.
14 # You should have received a copy of the GNU General Public License
15 # along with this program; if not, write to the Free Software
16 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
17 # USA.
20 from django.conf import settings
21 from django.conf.urls.defaults import *
23 # Uncomment the next two lines to enable the admin:
24 #from django.contrib import admin
25 #admin.autodiscover()
27 urlpatterns = patterns('',
28 (r'^', include('ganeti_web.urls')),
29 (r'^', include('object_permissions.urls')),
30 (r'^', include('object_log.urls')),
31 (r'^', include('muddle_users.urls')),
32 (r'^', include('muddle.urls')),
34 # user management
35 # account/activate/<key>/ - Activate a user
36 # account/activate/complete/ - Ater-activation page
37 # account/register/ - User registration form
38 # account/register/complete/ - After-registration page
39 # account/register/closed/ - No registration allowed page
40 # ---
41 # account/login - login page
42 # account/logout - logout page
43 # account/password/reset/ - send password reset email
44 # account/password/change/ - change current user password
46 # Authentication
47 url(r'^accounts/login/?', 'django.contrib.auth.views.login',
48 name="login",),
49 url(r'^accounts/logout/?', 'django.contrib.auth.views.logout',
50 {'next_page':'/'}, name="logout"),
51 (r'^accounts/', include('registration.urls')),
53 # Explicit 500 test route
54 (r'^500/$', 'django.views.generic.simple.direct_to_template',
55 {'template':"500.html"})
57 # Language settings
58 urlpatterns += patterns('',
59 (r'^i18n/', include('django.conf.urls.i18n')),
61 handler500 = 'ganeti_web.views.view_500'
64 #The following is used to serve up local media files like images
65 urlpatterns += patterns('',
66 (r'^favicon.ico', 'django.views.static.serve',
67 {'document_root': settings.MEDIA_ROOT, 'path': 'favicon.ico'}),
69 # noVNC files
70 (r'^novnc/(?P<path>.*)', 'django.views.static.serve',
71 {'document_root': '%s/noVNC/include' % settings.DOC_ROOT}),