diff options
author | Théophile Helleboid <theophile.helleboid@captaintrain.com> | 2019-05-02 17:34:44 +0200 |
---|---|---|
committer | Théophile Helleboid <theophile.helleboid@captaintrain.com> | 2019-05-02 17:34:44 +0200 |
commit | 29f3186f165565e03b3b091523f8b682be99404a (patch) | |
tree | 214db2306ef4a929da043d0209ca70bde78ee28b /tasks/postgres-common-postinstall.yml | |
parent | 0c83dd00b4110d55b1602ca8d732a8cb414cfd0a (diff) | |
download | ansible-postgresql-role-29f3186f165565e03b3b091523f8b682be99404a.tar.gz ansible-postgresql-role-29f3186f165565e03b3b091523f8b682be99404a.tar.zst ansible-postgresql-role-29f3186f165565e03b3b091523f8b682be99404a.zip |
Allow to use any ansible become method
The variable can be set to 'sudo' if ansible uses sudo
Diffstat (limited to 'tasks/postgres-common-postinstall.yml')
-rw-r--r-- | tasks/postgres-common-postinstall.yml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tasks/postgres-common-postinstall.yml b/tasks/postgres-common-postinstall.yml index 715782c..9be3bde 100644 --- a/tasks/postgres-common-postinstall.yml +++ b/tasks/postgres-common-postinstall.yml | |||
@@ -7,7 +7,7 @@ | |||
7 | command: ssh-keygen -b 4096 -f /var/lib/postgresql/.ssh/id_rsa -N "" -q | 7 | command: ssh-keygen -b 4096 -f /var/lib/postgresql/.ssh/id_rsa -N "" -q |
8 | become: yes | 8 | become: yes |
9 | become_user: postgres | 9 | become_user: postgres |
10 | become_method: su | 10 | become_method: "{{ postgres_become_method }}" |
11 | args: | 11 | args: |
12 | creates: /var/lib/postgresql/.ssh/id_rsa | 12 | creates: /var/lib/postgresql/.ssh/id_rsa |
13 | 13 | ||