From 6ec1dc97e2246442fc601b022a4baf783ce052ec Mon Sep 17 00:00:00 2001 From: "Dr. Jens Harbott" <harbott@osism.tech> Date: Mon, 22 Jan 2024 11:33:22 +0100 Subject: [PATCH] Update horizon local settings for Django 4 As horizon is now using Django 4 after a recent requirements update, we need to clean our config from settings that were long deprecated and now no longer work. [0] https://review.opendev.org/c/openstack/horizon/+/891828 [1] https://review.opendev.org/c/openstack/horizon/+/827092 Change-Id: I47533a2ad436578c98503284c25db4fd51896506 --- ansible/roles/horizon/templates/local_settings.j2 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ansible/roles/horizon/templates/local_settings.j2 b/ansible/roles/horizon/templates/local_settings.j2 index 7e47a5cfe9..494a85e27e 100644 --- a/ansible/roles/horizon/templates/local_settings.j2 +++ b/ansible/roles/horizon/templates/local_settings.j2 @@ -2,7 +2,7 @@ import os -from django.utils.translation import ugettext_lazy as _ +from django.utils.translation import gettext_lazy as _ from openstack_dashboard import exceptions from openstack_dashboard.settings import HORIZON_CONFIG @@ -178,7 +178,7 @@ SECRET_KEY='{{ horizon_secret_key }}' SESSION_ENGINE = 'django.contrib.sessions.backends.cache' CACHES = { 'default': { - 'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache', + 'BACKEND': 'django.core.cache.backends.memcached.PyMemcacheCache', 'LOCATION': [{% for host in groups['memcached'] %}'{{ 'api' | kolla_address(host) | put_address_in_context('memcache') }}:{{ memcached_port }}'{% if not loop.last %},{% endif %}{% endfor %}] } } -- GitLab