homeserver/roles/mgrote_postfix/handlers/main.yml
Michael Grote aa2eb3127a
All checks were successful
ci/woodpecker/push/gitleaks Pipeline was successful
ci/woodpecker/push/ansible-lint Pipeline was successful
mail: set FROM address (#91)
Reviewed-on: #91
2024-05-27 11:56:10 +02:00

13 lines
394 B
YAML

---
- name: reload postfix
become: true
ansible.builtin.systemd:
name: postfix
enabled: true
state: restarted
notify: send testmail
- name: send testmail # noqa no-changed-when
ansible.builtin.shell:
cmd: "set -o pipefail && echo 'postfix ist eingerichtet' | mail -aFROM:postfix@mgrote.net -s '{{ ansible_hostname }} - postfix' {{ my_mail }}"
executable: /bin/bash