This commit is contained in:
parent
4263d1be5a
commit
2059989d8a
4 changed files with 62 additions and 12 deletions
|
|
@ -8,11 +8,19 @@
|
|||
- postfix_mydestination is defined
|
||||
|
||||
- name: install packages
|
||||
package: name="{{ postfix_packages }}" state=latest update_cache=yes
|
||||
package:
|
||||
name: "{{ postfix_packages }}"
|
||||
state: present
|
||||
update_cache: yes
|
||||
notify: Restart postfix
|
||||
|
||||
- name: Deploy templates
|
||||
template: src=etc/postfix/{{ item }}.j2 dest=/etc/postfix/{{ item }} owner=root group=root mode=0644
|
||||
template:
|
||||
src: etc/postfix/{{ item }}.j2
|
||||
dest: /etc/postfix/{{ item }}
|
||||
owner: root
|
||||
group: root
|
||||
mode: 0644
|
||||
with_items:
|
||||
- main.cf
|
||||
- master.cf
|
||||
|
|
@ -74,7 +82,10 @@
|
|||
- postfix_mydestination is defined
|
||||
|
||||
- name: Enable postfix at boot time
|
||||
service: name=postfix enabled=yes state=started
|
||||
service:
|
||||
name: postfix
|
||||
enabled: yes
|
||||
state: started
|
||||
when:
|
||||
- postfix_mydestination is defined
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue