forked from ungleich-public/dynamicweb
Use Redis for the cache instead of memcached
CACHE_URL (default redis://redis:6379/1) feeds the built-in RedisCache backend. Redis is already part of compose for Celery, so this drops pylibmc, python-memcached and libmemcached-dev.
This commit is contained in:
parent
aeced67121
commit
88098f5b25
7 changed files with 3 additions and 15 deletions
|
|
@ -14,6 +14,7 @@ POSTGRES_HOST=db
|
|||
|
||||
CELERY_BROKER_URL=redis://redis:6379/0
|
||||
CELERY_RESULT_BACKEND=redis://redis:6379/0
|
||||
CACHE_URL=redis://redis:6379/1
|
||||
|
||||
# Host -> urlconf. Add the VPS IP / domain here if you access it that way.
|
||||
UNGLEICH_SITE_CONFIGS={"ungleich.ch":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"blog.ungleich.ch":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"comic.ungleich.ch":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"digitalglarus.ch":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"datacenterlight.ch":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"rails-hosting.ch":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"django-hosting.ch":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"node-hosting.ch":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"devuanhosting.ch":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"devuanhosting.com":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"ipv6onlyhosting.com":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"digitalezukunft.ch":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"hack4glarus.ch":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"xn--nglarus-n2a.ch":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"localhost:8000":{"MULTISITE_CMS_URL":"dynamicweb.urls"},"127.0.0.1:8000":{"MULTISITE_CMS_URL":"dynamicweb.urls"}}
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@ RUN apk add --update --no-cache \
|
|||
jpeg-dev \
|
||||
libxml2-dev \
|
||||
libxslt-dev \
|
||||
libmemcached-dev \
|
||||
zlib-dev \
|
||||
libffi-dev \
|
||||
&& rm -rf /var/cache/apk/*
|
||||
|
|
|
|||
|
|
@ -393,8 +393,8 @@ CMS_PERMISSION = True
|
|||
|
||||
CACHES = {
|
||||
'default': {
|
||||
'BACKEND': 'django.core.cache.backends.memcached.PyLibMCCache',
|
||||
'LOCATION': '127.0.0.1:11211',
|
||||
'BACKEND': 'django.core.cache.backends.redis.RedisCache',
|
||||
'LOCATION': env('CACHE_URL', 'redis://redis:6379/1'),
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -7,13 +7,6 @@ DEBUG = False
|
|||
|
||||
EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
|
||||
|
||||
CACHES = {
|
||||
'default': {
|
||||
'BACKEND': 'django.core.cache.backends.memcached.PyLibMCCache',
|
||||
'LOCATION': '127.0.0.1:11211',
|
||||
}
|
||||
}
|
||||
|
||||
# MANAGERS = ADMINS
|
||||
|
||||
REGISTRATION_MESSAGE['message'] = REGISTRATION_MESSAGE['message'].format(host='digitalglarus.ch',
|
||||
|
|
|
|||
|
|
@ -1,2 +1 @@
|
|||
base-devel
|
||||
libmemcached
|
||||
|
|
|
|||
|
|
@ -17,8 +17,6 @@ liblcms2-dev
|
|||
liblzma-dev
|
||||
libmagickcore-dev
|
||||
libmagickwand-dev
|
||||
libmemcached
|
||||
libmemcached-dev
|
||||
libncurses-dev
|
||||
libpq-dev
|
||||
libreadline-dev
|
||||
|
|
|
|||
|
|
@ -95,11 +95,9 @@ pyasn1==0.6.4
|
|||
pycodestyle==2.15.0
|
||||
pycryptodome==3.24.0
|
||||
pyflakes==4.0.2
|
||||
pylibmc==1.6.3
|
||||
pyotp==2.10.0
|
||||
python-dateutil==2.9.0.post0
|
||||
python-dotenv==1.2.4
|
||||
python-memcached==1.62
|
||||
python-slugify==9.1.2
|
||||
pytz==2026.5
|
||||
rcssmin==1.2.2
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue