---
- name: Verify
hosts: all
tasks:
- name: Check if msmtp is correctly listening on port 25
wait_for:
host: 0.0.0.0
port: 25
search_regex: 220 localhost ESMTP msmtpd
timeout: 5