From 9971624be146d6f15eefbacd514c8fcc109902c2 Mon Sep 17 00:00:00 2001 From: Mathias Behrle Date: Wed, 9 Nov 2022 10:12:53 +0100 Subject: [PATCH] [postgresql_server] Support postgresql 15 The stats_temp_directory entry was obsoleted with version 15. (cherry picked from commit 4f2efcdd40b120bec198713d8b5bc1e15e9a6de9) --- .../templates/etc/postgresql/postgresql.conf.j2 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ansible/roles/postgresql_server/templates/etc/postgresql/postgresql.conf.j2 b/ansible/roles/postgresql_server/templates/etc/postgresql/postgresql.conf.j2 index 38eee5f57d..9ce22b8521 100644 --- a/ansible/roles/postgresql_server/templates/etc/postgresql/postgresql.conf.j2 +++ b/ansible/roles/postgresql_server/templates/etc/postgresql/postgresql.conf.j2 @@ -375,7 +375,8 @@ track_io_timing = {{ item.track_io_timing | d('off') }} track_functions = {{ item.track_functions | d('none') }} track_activity_query_size = {{ item.track_activity_query_size | d('1024') }} update_process_title = {{ item.update_process_title | d('on') }} -{% if (item.version | d(postgresql_server__version)) is version_compare('9.1','>') %} +{% if (item.version | d(postgresql_server__version)) is version_compare('15','>=') %} +{% elif (item.version | d(postgresql_server__version)) is version_compare('9.1','>') %} stats_temp_directory = '{{ item.stats_temp_directory | d("/var/run/postgresql/" + (item.version | d(postgresql_server__version)) + "-" + item.name + ".pg_stat_tmp") }}' {% else %} stats_temp_directory = '{{ item.stats_temp_directory | d("pg_stat_tmp") }}'