Skip to content

Commit 8fd1b13

Browse files
authored
Merge pull request #173 from sandiegopython/davidfischer/remove-redis
Remove Redis from the cache configuration
2 parents f6da00e + c703ff6 commit 8fd1b13

File tree

3 files changed

+10
-20
lines changed

3 files changed

+10
-20
lines changed

config/settings/base.py

+10
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,16 @@
134134
SERVER_EMAIL = DEFAULT_FROM_EMAIL
135135

136136

137+
# Caching
138+
# https://docs.djangoproject.com/en/4.2/ref/settings/#caches
139+
# --------------------------------------------------------------------------
140+
CACHES = {
141+
"default": {
142+
"BACKEND": "django.core.cache.backends.locmem.LocMemCache",
143+
}
144+
}
145+
146+
137147
# Logging
138148
# A sample logging configuration. The only tangible logging
139149
# performed by this configuration is to send an email to

config/settings/prod.py

-17
Original file line numberDiff line numberDiff line change
@@ -58,23 +58,6 @@
5858
DATABASES["default"]["CONN_MAX_AGE"] = 600
5959

6060

61-
# Caching
62-
# https://docs.djangoproject.com/en/4.2/ref/settings/#caches
63-
# http://niwinz.github.io/django-redis/
64-
# --------------------------------------------------------------------------
65-
if "REDIS_URL" in os.environ:
66-
CACHES = {
67-
"default": {
68-
"BACKEND": "django_redis.cache.RedisCache",
69-
"LOCATION": os.environ["REDIS_URL"],
70-
"OPTIONS": {
71-
"CLIENT_CLASS": "django_redis.client.DefaultClient",
72-
"IGNORE_EXCEPTIONS": True,
73-
},
74-
}
75-
}
76-
77-
7861
# Security
7962
# https://docs.djangoproject.com/en/4.2/topics/security/
8063
# --------------------------------------------------------------------------

requirements/deployment.txt

-3
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@
33
# Database server
44
psycopg2-binary==2.9.9
55

6-
# Caching
7-
django-redis==5.4.0
8-
96
# Email
107
django-anymail==10.3
118

0 commit comments

Comments
 (0)