MEDIA_ROOT -> STATIC_ROOT - apparently we don't really use MEDIA_ROOT at the moment since all files are handled not through file fields, but through explicit management of their paths
- Legacy-Id: 6980
This commit is contained in:
parent
2cefdd7410
commit
b84440b857
|
@ -83,13 +83,12 @@ SITE_ID = 1
|
||||||
# to load the internationalization machinery.
|
# to load the internationalization machinery.
|
||||||
USE_I18N = False
|
USE_I18N = False
|
||||||
|
|
||||||
# Absolute path to the directory that holds media.
|
USE_TZ = False
|
||||||
MEDIA_ROOT = BASE_DIR + "/../static/"
|
|
||||||
|
|
||||||
# URL that handles the media served from MEDIA_ROOT.
|
|
||||||
MEDIA_URL = 'http://www.ietf.org/'
|
MEDIA_URL = 'http://www.ietf.org/'
|
||||||
|
|
||||||
STATIC_URL = "/"
|
STATIC_URL = "/"
|
||||||
|
STATIC_ROOT = os.path.abspath(BASE_DIR + "/../static/")
|
||||||
|
|
||||||
WSGI_APPLICATION = "ietf.wsgi.application"
|
WSGI_APPLICATION = "ietf.wsgi.application"
|
||||||
|
|
||||||
|
|
|
@ -68,10 +68,10 @@ urlpatterns = patterns('',
|
||||||
|
|
||||||
if settings.SERVER_MODE in ('development', 'test'):
|
if settings.SERVER_MODE in ('development', 'test'):
|
||||||
urlpatterns += patterns('',
|
urlpatterns += patterns('',
|
||||||
(r'^(?P<path>(?:images|css|js)/.*)$', 'django.views.static.serve', {'document_root': settings.MEDIA_ROOT}),
|
(r'^(?P<path>(?:images|css|js)/.*)$', 'django.views.static.serve', {'document_root': settings.STATIC_ROOT}),
|
||||||
(r'^(?P<path>admin/(?:img|css|js)/.*)$', 'django.views.static.serve', {'document_root': settings.MEDIA_ROOT}),
|
(r'^(?P<path>admin/(?:img|css|js)/.*)$', 'django.views.static.serve', {'document_root': settings.STATIC_ROOT}),
|
||||||
(r'^(?P<path>secretariat/(img|css|js)/.*)$', 'django.views.static.serve', {'document_root': settings.MEDIA_ROOT}),
|
(r'^(?P<path>secretariat/(img|css|js)/.*)$', 'django.views.static.serve', {'document_root': settings.STATIC_ROOT}),
|
||||||
(r'^(?P<path>robots\.txt)$', 'django.views.static.serve', {'document_root': settings.MEDIA_ROOT+"dev/"}),
|
(r'^(?P<path>robots\.txt)$', 'django.views.static.serve', {'document_root': settings.STATIC_ROOT+"dev/"}),
|
||||||
(r'^_test500/$', lambda x: None),
|
(r'^_test500/$', lambda x: None),
|
||||||
(r'^environment/$', 'ietf.help.views.environment'),
|
(r'^environment/$', 'ietf.help.views.environment'),
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in a new issue