Fix the loop tasks.

This commit is contained in:
Andrea Dell'Amico 2021-04-06 14:33:15 +02:00
parent 7f52dbbe4f
commit 1d447c464a
1 changed files with 3 additions and 5 deletions

View File

@ -15,7 +15,7 @@
value: "{{ item.value }}"
loop: '{{ psql_streaming_replication_config }}'
#when: postgresql_streaming_replication_primary_node == '{{ ansible_fqdn }}'
notify: Reload postgresql
notify: Restart postgresql
become: True
become_user: postgres
@ -31,8 +31,7 @@
address: '{{ item }}'
method: 'scram-sha-256'
state: present
loop:
- '{{ psql_streaming_replication_hosts }}'
loop: '{{ psql_streaming_replication_hosts }}'
notify: Reload postgresql
when: ansible_distribution_file_variety == "Debian"
tags: [ 'postgresql', 'postgres', 'pg_conf', 'pg_hba', 'postgresql_replication' ]
@ -47,8 +46,7 @@
address: '{{ item }}'
method: 'scram-sha-256'
state: present
loop:
- '{{ psql_streaming_replication_hosts }}'
loop: '{{ psql_streaming_replication_hosts }}'
notify: Reload postgresql
when: ansible_distribution_file_variety == "RedHat"
tags: [ 'postgresql', 'postgres', 'pg_conf', 'pg_hba', 'postgresql_replication' ]