From bc9a0fefa35153bdded8273c91a966fdc669a1ba Mon Sep 17 00:00:00 2001 From: Andrea Dell'Amico Date: Thu, 30 Jul 2020 19:04:12 +0200 Subject: [PATCH] Create the log directory on EL. --- tasks/postgresql-config.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tasks/postgresql-config.yml b/tasks/postgresql-config.yml index 22be74f..a2563a0 100644 --- a/tasks/postgresql-config.yml +++ b/tasks/postgresql-config.yml @@ -101,6 +101,13 @@ - name: Configuration of EL systems block: + + - name: Create the postgresql log directory + file: dest={{ psql_log_dir }} owner=postgres group=postgres mode='0750' + + - name: Fix the SELinux rules for the postgresql log directory + shell: semanage fcontext -a -a -t postgresql_db_t "{{ psql_log_dir }}(/.*)?" && restorecon -vR {{ psql_log_dir }} + - name: Set some postgresql configuration parameters that require a db restart become: True become_user: postgres