summaryrefslogtreecommitdiff
path: root/settings.py
diff options
context:
space:
mode:
Diffstat (limited to 'settings.py')
-rw-r--r--settings.py26
1 files changed, 26 insertions, 0 deletions
diff --git a/settings.py b/settings.py
index 8b74e554..80df6f43 100644
--- a/settings.py
+++ b/settings.py
@@ -78,6 +78,7 @@ MIDDLEWARE_CLASSES = (
'django.middleware.doc.XViewMiddleware',
)
+# Base of the URL hierarchy
ROOT_URLCONF = 'urls'
# URL to serve static files
@@ -123,6 +124,31 @@ INSTALLED_APPS = (
'retro',
)
+# Logging configuration for not getting overspammed
+LOGGING = {
+ 'version': 1,
+ 'filters': {
+ 'ratelimit': {
+ '()': 'main.log.RateLimitFilter',
+ }
+ },
+ 'handlers': {
+ 'mail_admins': {
+ 'level': 'ERROR',
+ 'filters': ['ratelimit'],
+ 'class': 'django.utils.log.AdminEmailHandler',
+ }
+ },
+ 'loggers': {
+ 'django.request': {
+ 'handlers': ['mail_admins'],
+ 'level': 'ERROR',
+ 'propagate': True,
+ },
+ },
+}
+
+
## Server used for linking to PGP keysearch results
PGP_SERVER = 'pgp.mit.edu:11371'