Add settings and Postgres reload handler

This commit is contained in:
Sam A. 2023-11-26 20:02:55 +01:00
parent ecc56cf778
commit 259a396319
Signed by: samsapti
GPG key ID: CBBBE7371E81C4EA
4 changed files with 13 additions and 1 deletions

View file

@ -1,3 +1,8 @@
[defaults] [defaults]
ask_vault_pass = True
inventory = inventory.ini
interpreter_python = /usr/bin/python3
remote_user = ansible
remote_tmp = /tmp/.ansible remote_tmp = /tmp/.ansible
use_persistent_connections = true use_persistent_connections = True
forks = 10

View file

@ -1,6 +1,11 @@
# vim: ft=yaml.ansible # vim: ft=yaml.ansible
# code: language=ansible # code: language=ansible
--- ---
- name: Reload PostgreSQL
ansible.builtin.service:
name: "{{ postgresql_service }}"
state: reloaded
- name: Reload systemd - name: Reload systemd
ansible.builtin.systemd: ansible.builtin.systemd:
daemon_reload: true daemon_reload: true

View file

@ -33,3 +33,4 @@
source: "{{ internal_subnet }}" source: "{{ internal_subnet }}"
method: scram-sha-256 method: scram-sha-256
state: present state: present
notify: Reload PostgreSQL

View file

@ -22,6 +22,7 @@
- postgresql{{ postgresql_version }}-server - postgresql{{ postgresql_version }}-server
- python{{ ansible_python.version.major }}-psycopg2 - python{{ ansible_python.version.major }}-psycopg2
- python{{ ansible_python.version.major }}-ipaddress - python{{ ansible_python.version.major }}-ipaddress
update_cache: true
state: present state: present
- name: Create PostgreSQL service override folder - name: Create PostgreSQL service override folder