From fb20e91a7d69a7d91a3e6cc5577c886306efda6c Mon Sep 17 00:00:00 2001 From: Martin Mahner Date: Sat, 28 Sep 2013 12:34:57 +0200 Subject: [PATCH] Added session cache backend. Added redis. Updated requirements. --- dpaste/settings.py | 13 ++++++++++++- requirements.txt | 9 +++++---- 2 files changed, 17 insertions(+), 5 deletions(-) diff --git a/dpaste/settings.py b/dpaste/settings.py index e709c29..251acf9 100644 --- a/dpaste/settings.py +++ b/dpaste/settings.py @@ -97,7 +97,6 @@ TEMPLATE_CONTEXT_PROCESSORS += ( ) INSTALLED_APPS = ( - 'django.contrib.sessions', 'django.contrib.staticfiles', 'mptt', 'south', @@ -114,6 +113,18 @@ DATABASES = { } } +SESSION_ENGINE = 'django.contrib.sessions.backends.cache' + +CACHES = { + "default": { + "BACKEND": "redis_cache.cache.RedisCache", + "LOCATION": "127.0.0.1:6379:1", + "OPTIONS": { + "CLIENT_CLASS": "redis_cache.client.DefaultClient", + } + } +} + #============================================================================== # App specific settings #============================================================================== diff --git a/requirements.txt b/requirements.txt index 1f63924..b03c1db 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,9 +1,10 @@ -django==1.5.2 +django==1.5.4 django-mptt==0.6.0 +django-redis==3.3 pygments==1.6 south==0.8.2 -requests==1.2.3 +requests==2.0.0 # Deployment specific -#mysql-python==1.2.4 -gunicorn==17.5 +gunicorn==18.0 +mysql-python==1.2.4 \ No newline at end of file