summaryrefslogtreecommitdiffstats
path: root/apps/settings.py
diff options
context:
space:
mode:
authorStephen Finucane <stephenfinucane@hotmail.com>2015-04-07 22:20:53 +0100
committerJeremy Kerr <jk@ozlabs.org>2015-05-03 13:46:52 +0800
commitd4a2c1f8792f52fec0c881ab38c91635840a50c0 (patch)
treef08cb31b6c2ad4a80bacbf9ba8a2b8b2b2cdca6d /apps/settings.py
parentc641660e041fdf932bad89681c167328ee85249a (diff)
downloadpatchwork-d4a2c1f8792f52fec0c881ab38c91635840a50c0.tar.bz2
patchwork-d4a2c1f8792f52fec0c881ab38c91635840a50c0.tar.xz
Integrate 'django.contrib.staticfiles'
Rather than providing a custom solution for serving static files, use the solution provided in the upstream Django source. This allows us to remove the top-level 'urls.py' file. Signed-off-by: Stephen Finucane <stephenfinucane@hotmail.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'apps/settings.py')
-rw-r--r--apps/settings.py17
1 files changed, 14 insertions, 3 deletions
diff --git a/apps/settings.py b/apps/settings.py
index dbe0544..01add3e 100644
--- a/apps/settings.py
+++ b/apps/settings.py
@@ -19,6 +19,7 @@ INSTALLED_APPS = (
'django.contrib.sessions',
'django.contrib.sites',
'django.contrib.admin',
+ 'django.contrib.staticfiles',
'patchwork',
)
@@ -78,7 +79,7 @@ USE_I18N = True
# URLs
-ROOT_URLCONF = 'urls'
+ROOT_URLCONF = 'patchwork.urls'
# Security
@@ -99,8 +100,6 @@ TEMPLATE_DIRS = (
# https://docs.djangoproject.com/en/1.6/ref/settings/#auth
#
-ADMIN_MEDIA_PREFIX = '/media/'
-
LOGIN_URL = '/user/login/'
LOGIN_REDIRECT_URL = '/user/'
@@ -114,6 +113,18 @@ SITE_ID = 1
#
+# Static files settings
+# https://docs.djangoproject.com/en/1.6/ref/settings/#static-files
+#
+
+STATIC_URL = '/static/'
+
+STATICFILES_DIRS = [
+ os.path.join(ROOT_DIR, 'htdocs'),
+]
+
+
+#
# Patchwork settings
#