From 59da07920be5eb561446c0ead08bf870263f0cd5 Mon Sep 17 00:00:00 2001 From: Michal Arbet <michal.arbet@ultimum.io> Date: Sun, 10 Mar 2024 10:39:31 +0100 Subject: [PATCH] Fix coordination when redis used Tooz 6.0.1 includes commit [1], which introduced parsing the username from the Redis connection URL. As a result, services started authenticating as admin which, by the way, was incorrect even before, as either a created user or the default one should have been used. The reason it worked before is simply because the username 'admin' wasn't parsed anywhere. This patch fixes the user being used and sets the correct 'default' one. [1] https://review.opendev.org/c/openstack/tooz/+/907656 Closes-Bug: #2056667 Depends-On: https://review.opendev.org/c/openstack/kolla/+/911703 Change-Id: I5568dba15fa98e009ad4a9e41756aba0fa659371 --- ansible/group_vars/all.yml | 2 +- releasenotes/notes/bug-2056667-c6d6896855b393f4.yaml | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 releasenotes/notes/bug-2056667-c6d6896855b393f4.yaml diff --git a/ansible/group_vars/all.yml b/ansible/group_vars/all.yml index 695f7a85a3..ba42c2b9f2 100644 --- a/ansible/group_vars/all.yml +++ b/ansible/group_vars/all.yml @@ -944,7 +944,7 @@ enable_opensearch_dashboards_external: "{{ enable_opensearch_dashboards | bool } #################### # Redis options #################### -redis_connection_string: "redis://{% for host in groups['redis'] %}{% if host == groups['redis'][0] %}admin:{{ redis_master_password }}@{{ 'api' | kolla_address(host) | put_address_in_context('url') }}:{{ redis_sentinel_port }}?sentinel=kolla{% else %}&sentinel_fallback={{ 'api' | kolla_address(host) | put_address_in_context('url') }}:{{ redis_sentinel_port }}{% endif %}{% endfor %}{{ redis_connection_string_extras }}" +redis_connection_string: "redis://{% for host in groups['redis'] %}{% if host == groups['redis'][0] %}default:{{ redis_master_password }}@{{ 'api' | kolla_address(host) | put_address_in_context('url') }}:{{ redis_sentinel_port }}?sentinel=kolla{% else %}&sentinel_fallback={{ 'api' | kolla_address(host) | put_address_in_context('url') }}:{{ redis_sentinel_port }}{% endif %}{% endfor %}{{ redis_connection_string_extras }}" redis_connection_string_extras: "&db=0&socket_timeout=60&retry_on_timeout=yes" #################### diff --git a/releasenotes/notes/bug-2056667-c6d6896855b393f4.yaml b/releasenotes/notes/bug-2056667-c6d6896855b393f4.yaml new file mode 100644 index 0000000000..b6677b820d --- /dev/null +++ b/releasenotes/notes/bug-2056667-c6d6896855b393f4.yaml @@ -0,0 +1,5 @@ +--- +fixes: + - | + Fixes the use of redis as coordination backend. + `LP#2056667 <https://bugs.launchpad.net/kolla-ansible/+bug/2056667>`__ -- GitLab