fix variables
This commit is contained in:
parent
4bfaf60650
commit
502b21a656
@ -16,18 +16,18 @@
|
|||||||
become: True
|
become: True
|
||||||
become_user: root
|
become_user: root
|
||||||
|
|
||||||
- name: Ensure linux user '{{ postgresql_users }}' is present
|
- name: Ensure linux user '{{ postgres_user }}' is present
|
||||||
user:
|
user:
|
||||||
name: "{{ item.name }}"
|
name: "{{ item.name }}"
|
||||||
password: "{{ item.password }}"
|
password: "{{ item.password }}"
|
||||||
with_items: "{{ postgresql_users }}"
|
with_items: "{{ postgres_users }}"
|
||||||
when: item.name == postgres_user
|
when: item.name == postgres_user
|
||||||
|
|
||||||
- name: Force all notified handlers to activate pg_hba.conf
|
- name: Force all notified handlers to activate pg_hba.conf
|
||||||
meta: flush_handlers
|
meta: flush_handlers
|
||||||
|
|
||||||
- name: Ensure PostgreSQL users are present
|
- name: Ensure PostgreSQL users are present
|
||||||
postgresql_user:
|
postgres_user:
|
||||||
name: "{{ item.name }}"
|
name: "{{ item.name }}"
|
||||||
password: "{{ item.password | default(omit) }}"
|
password: "{{ item.password | default(omit) }}"
|
||||||
encrypted: "{{ item.encrypted | default('yes') }}"
|
encrypted: "{{ item.encrypted | default('yes') }}"
|
||||||
@ -36,12 +36,12 @@
|
|||||||
db: "{{ item.db | default(omit) }}"
|
db: "{{ item.db | default(omit) }}"
|
||||||
login_host: "{{ item.login_host | default('localhost') }}"
|
login_host: "{{ item.login_host | default('localhost') }}"
|
||||||
login_password: "{{ item.login_password | default(omit) }}"
|
login_password: "{{ item.login_password | default(omit) }}"
|
||||||
login_user: "{{ item.login_user | default(postgresql_user) }}"
|
login_user: "{{ item.login_user | default(postgres_user) }}"
|
||||||
login_unix_socket: "{{ item.login_unix_socket | default(postgresql_unix_socket_directories[0]) }}"
|
login_unix_socket: "{{ item.login_unix_socket | default(postgres_socket_directories[0]) }}"
|
||||||
port: "{{ item.port | default(omit) }}"
|
port: "{{ item.port | default(omit) }}"
|
||||||
state: "{{ item.state | default('present') }}"
|
state: "{{ item.state | default('present') }}"
|
||||||
with_items: "{{ postgresql_users }}"
|
with_items: "{{ postgres_users }}"
|
||||||
loop_control:
|
loop_control:
|
||||||
label: "{{ item.name }}"
|
label: "{{ item.name }}"
|
||||||
become: true
|
become: true
|
||||||
become_user: "{{ postgresql_user }}"
|
become_user: "{{ postgres_user }}"
|
||||||
|
Loading…
Reference in New Issue
Block a user