Skip to content

Commit

Permalink
Pgpool2: run PG dedicated user creation only once
Browse files Browse the repository at this point in the history
  • Loading branch information
jt-edb committed Jan 19, 2021
1 parent 579d74f commit f0bbc12
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions roles/setup_pgpool2/tasks/pgpool2_setup_sr_mode.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
set_fact:
pgpool2_sr_check_password: >-
{{ lookup('password', '/dev/null chars=ascii_letters,digits length=12') }}
run_once: true
when:
- pgpool2_sr_check_password|length == 0

Expand All @@ -21,6 +22,7 @@
- name: "{{ pgpool2_sr_check_user }}"
pass: "{{ pgpool2_sr_check_password }}"
role_attr_flags: login
run_once: true
when:
- pgpool2_primary_public_ip is defined
- pgpool2_primary_public_ip|length > 0
Expand Down

0 comments on commit f0bbc12

Please sign in to comment.