2 # This file is part of my.gpodder.org.
4 # my.gpodder.org is free software: you can redistribute it and/or modify it
5 # under the terms of the GNU Affero General Public License as published by
6 # the Free Software Foundation, either version 3 of the License, or (at your
7 # option) any later version.
9 # my.gpodder.org is distributed in the hope that it will be useful, but
10 # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
11 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public
12 # License for more details.
14 # You should have received a copy of the GNU Affero General Public License
15 # along with my.gpodder.org. If not, see <http://www.gnu.org/licenses/>.
19 from django
.conf
.urls
import include
, url
20 from django
.contrib
import admin
21 from django
.conf
import settings
22 from django
.contrib
.staticfiles
.views
import serve
24 # strip the leading "/"
25 static_prefix
= settings
.STATIC_URL
[1:]
27 # This URLs should be always be served, even during maintenance mode
29 url(r
'^%s(?P<path>.*)$' % static_prefix
, serve
)
33 # Check for maintenace mode
34 from django
.conf
import settings
35 if settings
.MAINTENANCE
:
36 from mygpo
.web
import utils
38 url(r
'', utils
.maintenance
),
42 # URLs are still registered during maintenace mode because we need to
43 # build links from them (eg login-link).
45 url(r
'^', include('mygpo.web.urls')),
46 url(r
'^', include('mygpo.podcasts.urls')),
47 url(r
'^', include('mygpo.directory.urls')),
48 url(r
'^', include('mygpo.api.urls')),
49 url(r
'^', include('mygpo.userfeeds.urls')),
50 url(r
'^', include('mygpo.share.urls')),
51 url(r
'^', include('mygpo.history.urls')),
52 url(r
'^', include('mygpo.subscriptions.urls')),
53 url(r
'^', include('mygpo.users.urls')),
54 url(r
'^', include('mygpo.podcastlists.urls')),
55 url(r
'^suggestions/', include('mygpo.suggestions.urls')),
56 url(r
'^publisher/', include('mygpo.publisher.urls')),
57 url(r
'^administration/', include('mygpo.administration.urls')),
58 url(r
'^pubsub/', include('mygpo.pubsub.urls')),
59 url(r
'^admin/', include(admin
.site
.urls
)),