From c218bbe239bf5090c8132ae6dc9ad054015e00c1 Mon Sep 17 00:00:00 2001 From: Baptiste Mispelon Date: Wed, 26 Jun 2024 18:48:06 +0200 Subject: [PATCH] Used redis cache for default as well --- djangoproject/settings/prod.py | 9 ++++----- requirements/prod.txt | 2 -- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/djangoproject/settings/prod.py b/djangoproject/settings/prod.py index 5693f5aff..37b70717c 100644 --- a/djangoproject/settings/prod.py +++ b/djangoproject/settings/prod.py @@ -14,14 +14,13 @@ CACHES = { "default": { - "BACKEND": "django_pylibmc.memcached.PyLibMCCache", - "LOCATION": SECRETS.get("memcached_host", "127.0.0.1:11211"), - "BINARY": True, - "OPTIONS": {"tcp_nodelay": True, "ketama": True}, + "BACKEND": "django.core.cache.backends.redis.RedisCache", + "LOCATION": SECRETS.get("cache_default_url", "redis://localhost:6379"), }, + # We use a separate cache for docs so we can purge it when docs are rebuilt "docs-pages": { "BACKEND": "django.core.cache.backends.redis.RedisCache", - "LOCATION": SECRETS.get("redis_host", "redis://localhost:6379/2"), + "LOCATION": SECRETS.get("cache_docs_url", "redis://localhost:6379/2"), }, } diff --git a/requirements/prod.txt b/requirements/prod.txt index c41ef0efe..b279f9729 100644 --- a/requirements/prod.txt +++ b/requirements/prod.txt @@ -1,5 +1,3 @@ -r common.txt -django-pylibmc==0.6.1 -pylibmc==1.6.1 redis==5.0.7 sentry-sdk==1.44.1