use become
This commit is contained in:
parent
7e19f2faca
commit
0692148543
@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
- name: Restart postfix
|
- name: Restart service
|
||||||
service:
|
service:
|
||||||
name: postfix
|
name: postfix
|
||||||
state: restarted
|
state: restarted
|
||||||
|
@ -1,4 +1,6 @@
|
|||||||
---
|
---
|
||||||
|
- name: Setup postfix
|
||||||
|
block:
|
||||||
- name: Configure postfix
|
- name: Configure postfix
|
||||||
template:
|
template:
|
||||||
src: etc/postfix/main.cf.j2
|
src: etc/postfix/main.cf.j2
|
||||||
@ -55,3 +57,4 @@
|
|||||||
when: not senderdb.stat.exists or sender_result.changed
|
when: not senderdb.stat.exists or sender_result.changed
|
||||||
register: senderdb_update
|
register: senderdb_update
|
||||||
notify: postfix_restart
|
notify: postfix_restart
|
||||||
|
become: True
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
---
|
---
|
||||||
- name: Install postfix mta
|
- name: Install postfix mta
|
||||||
|
block:
|
||||||
|
- name: Install required packages
|
||||||
package:
|
package:
|
||||||
name: '{{ item }}'
|
name: '{{ item }}'
|
||||||
state: latest
|
state: latest
|
||||||
@ -7,3 +9,4 @@
|
|||||||
- postfix
|
- postfix
|
||||||
- cyrus-sasl-plain
|
- cyrus-sasl-plain
|
||||||
- mailx
|
- mailx
|
||||||
|
become: True
|
||||||
|
Loading…
Reference in New Issue
Block a user