Fixes
This commit is contained in:
parent
3c419fd21f
commit
472ac725e5
2 changed files with 4 additions and 3 deletions
|
@ -32,6 +32,9 @@
|
||||||
ansible.builtin.include_tasks: mta-sts.yml
|
ansible.builtin.include_tasks: mta-sts.yml
|
||||||
tags: mta-sts
|
tags: mta-sts
|
||||||
loop: "{{ postfix_domains }}"
|
loop: "{{ postfix_domains }}"
|
||||||
|
args:
|
||||||
|
apply:
|
||||||
|
delegate_to: "{{ gateway_host }}"
|
||||||
|
|
||||||
- name: Hostname
|
- name: Hostname
|
||||||
ansible.builtin.import_tasks: hostname.yml
|
ansible.builtin.import_tasks: hostname.yml
|
||||||
|
|
|
@ -4,13 +4,13 @@
|
||||||
src: nginx/mta-sts.txt.j2
|
src: nginx/mta-sts.txt.j2
|
||||||
dest: /var/www/html/mta-sts.txt
|
dest: /var/www/html/mta-sts.txt
|
||||||
mode: "0644"
|
mode: "0644"
|
||||||
|
when: item.mta_sts is defined and item.mta_sts
|
||||||
|
|
||||||
- name: "MTA-STS | Get certificate"
|
- name: "MTA-STS | Get certificate"
|
||||||
ansible.builtin.lineinfile:
|
ansible.builtin.lineinfile:
|
||||||
path: /etc/dehydrated/domains.txt
|
path: /etc/dehydrated/domains.txt
|
||||||
line: "mta-sts.{{ item.name }}"
|
line: "mta-sts.{{ item.name }}"
|
||||||
when: "'dehydrated' in ansible_facts.packages and item.mta_sts is defined and item.mta_sts"
|
when: "'dehydrated' in ansible_facts.packages and item.mta_sts is defined and item.mta_sts"
|
||||||
loop: "{{ postfix_domains }}"
|
|
||||||
notify: Get certificate
|
notify: Get certificate
|
||||||
|
|
||||||
- name: "MTA-STS | Copy Nginx configuration"
|
- name: "MTA-STS | Copy Nginx configuration"
|
||||||
|
@ -19,7 +19,6 @@
|
||||||
dest: "/etc/nginx/sites-available/mta-sts.{{ item.name }}"
|
dest: "/etc/nginx/sites-available/mta-sts.{{ item.name }}"
|
||||||
mode: "0644"
|
mode: "0644"
|
||||||
when: item.mta_sts is defined and item.mta_sts
|
when: item.mta_sts is defined and item.mta_sts
|
||||||
loop: "{{ postfix_domains }}"
|
|
||||||
|
|
||||||
- name: "MTA-STS | Enable Nginx configuration"
|
- name: "MTA-STS | Enable Nginx configuration"
|
||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
|
@ -27,5 +26,4 @@
|
||||||
dest: "/etc/nginx/sites-enabled/mta-sts.{{ item.name }}"
|
dest: "/etc/nginx/sites-enabled/mta-sts.{{ item.name }}"
|
||||||
state: link
|
state: link
|
||||||
when: item.mta_sts is defined and item.mta_sts
|
when: item.mta_sts is defined and item.mta_sts
|
||||||
loop: "{{ postfix_domains }}"
|
|
||||||
notify: reload nginx
|
notify: reload nginx
|
||||||
|
|
Loading…
Reference in a new issue