fix: adapt to PG15
This commit is contained in:
@@ -21,16 +21,19 @@
|
|||||||
become_user: postgres
|
become_user: postgres
|
||||||
notify: Restart postgres
|
notify: Restart postgres
|
||||||
|
|
||||||
- name: Put main configuration files
|
- name: Put hba configuration files
|
||||||
ansible.builtin.copy:
|
ansible.builtin.copy:
|
||||||
src: "{{ item.src }}"
|
src: "files/pg_hba.conf"
|
||||||
dest: "{{ item.dest }}"
|
dest: "/etc/postgresql/{{ pg_version }}/main/pg_hba.conf"
|
||||||
mode: "{{ item.mode }}"
|
mode: "0640"
|
||||||
loop:
|
|
||||||
- {src: "files/postgresql.conf", dest: "/etc/postgresql/{{ pg_version }}/main/postgresql.conf", mode: "0644"}
|
|
||||||
- {src: "files/pg_hba.conf", dest: "/etc/postgresql/{{ pg_version }}/main/pg_hba.conf", mode: "0640"}
|
|
||||||
notify: Restart postgres
|
notify: Restart postgres
|
||||||
|
|
||||||
|
- name: Put main configuration files
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "postgresql.conf.j2"
|
||||||
|
dest: "/etc/postgresql/{{ pg_version }}/main/postgresql.conf"
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
- name: Create backup dir
|
- name: Create backup dir
|
||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
path: /srv/backup/pgsql
|
path: /srv/backup/pgsql
|
||||||
|
@@ -40,13 +40,13 @@
|
|||||||
|
|
||||||
data_directory = '/srv/postgresql' # use data in another directory
|
data_directory = '/srv/postgresql' # use data in another directory
|
||||||
# (change requires restart)
|
# (change requires restart)
|
||||||
hba_file = '/etc/postgresql/13/main/pg_hba.conf' # host-based authentication file
|
hba_file = '/etc/postgresql/{{ pg_version }}/main/pg_hba.conf' # host-based authentication file
|
||||||
# (change requires restart)
|
# (change requires restart)
|
||||||
ident_file = '/etc/postgresql/13/main/pg_ident.conf' # ident configuration file
|
ident_file = '/etc/postgresql/{{ pg_version }}/main/pg_ident.conf' # ident configuration file
|
||||||
# (change requires restart)
|
# (change requires restart)
|
||||||
|
|
||||||
# If external_pid_file is not explicitly set, no extra PID file is written.
|
# If external_pid_file is not explicitly set, no extra PID file is written.
|
||||||
external_pid_file = '/var/run/postgresql/13-main.pid' # write an extra PID file
|
external_pid_file = '/var/run/postgresql/{{ pg_version }}-main.pid' # write an extra PID file
|
||||||
# (change requires restart)
|
# (change requires restart)
|
||||||
|
|
||||||
|
|
||||||
@@ -484,7 +484,7 @@ log_timezone = 'Europe/Paris'
|
|||||||
# PROCESS TITLE
|
# PROCESS TITLE
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
|
|
||||||
cluster_name = '13/main' # added to process titles if nonempty
|
cluster_name = '{{ pg_version }}/main' # added to process titles if nonempty
|
||||||
# (change requires restart)
|
# (change requires restart)
|
||||||
#update_process_title = on
|
#update_process_title = on
|
||||||
|
|
||||||
@@ -500,7 +500,7 @@ cluster_name = '13/main' # added to process titles if nonempty
|
|||||||
#track_io_timing = off
|
#track_io_timing = off
|
||||||
#track_functions = none # none, pl, all
|
#track_functions = none # none, pl, all
|
||||||
#track_activity_query_size = 1024 # (change requires restart)
|
#track_activity_query_size = 1024 # (change requires restart)
|
||||||
stats_temp_directory = '/var/run/postgresql/13-main.pg_stat_tmp'
|
#stats_temp_directory = '/var/run/postgresql/{{ pg_version }}-main.pg_stat_tmp'
|
||||||
|
|
||||||
|
|
||||||
# - Monitoring -
|
# - Monitoring -
|
Reference in New Issue
Block a user