From f041ffd4adb31f25313f1fb46925c2e63ee44f58 Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Tue, 28 Feb 2023 14:52:02 +0900 Subject: [PATCH] Horizon: Completely switch to PyMemcache backend We replaced[1] the deprecated MemcachedCache backend in CentOS[1] but has been using the deprecated backend in Ubuntu because of the old package in Ubuntu Focal. Now we use Ubuntu Jammy which provides python3-pymemcache 3.5.0, so can use PyMemcacheCache backend [1] a0bfa42751c35358f135e791f90af97e6d92cf32 Change-Id: I609b8a7da6668185294d50b92344fbfa1d3f9db2 --- manifests/horizon.pp | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/manifests/horizon.pp b/manifests/horizon.pp index a74311453..44667bddf 100644 --- a/manifests/horizon.pp +++ b/manifests/horizon.pp @@ -41,17 +41,9 @@ class openstack_integration::horizon ( Exec['update-ca-certificates'] ~> Service['httpd'] } - # TODO(tkajinam): Switch to pymemcache backend when we bump Ubuntu from - # Focal to Jammy. The pymemcache package in Forcal is too old - # and is not compatible with Django. - $cache_backend = $facts['os']['family'] ? { - 'Debian' => 'django.core.cache.backends.memcached.MemcachedCache', - default => 'django.core.cache.backends.memcached.PyMemcacheCache' - } - class { 'horizon': secret_key => 'big_secret', - cache_backend => $cache_backend, + cache_backend => 'django.core.cache.backends.memcached.PyMemcacheCache', cache_server_ip => $::openstack_integration::config::host, allowed_hosts => $::openstack_integration::config::ip_for_url, listen_ssl => $::openstack_integration::config::ssl,