No bells and whistles email, plain Dovecot and Exim4 setup for Debian boxes.
Role Variables
email_server_external_ip
email_users
: Dictionary withuser
andpassword
andquota
keys. When quota is not present, there are no limits.email_domain_zone
: Your domain (eg:foo.com
).email_domain_ns_provider
: Only Cloudflare is supported (Default:cloudflare
).email_certificates_path
: Dictionary withcertificate
andkey
keys. When both keys have a value, LetsEncrypt certificates are not generated. Your certificate should be a full chain and must be valid for the following subdomains:mail
smtp
imap
cloudflare
: Dictionary withemail
andapi_key
keys, only required whenemail_domain_ns_provider == cloudflare
.
Requirements
- 25 (SMTP) TCP
- 587 (SMTP) TCP
- 993 (IMAP) TCP
- 143 (IMAP) TCP
- 4190 (Sieve) TCP
Dependencies
geerlingguy.certbot
Example Playbook
- hosts: foo
become: yes
gather_facts: yes
roles:
- name: email
vars:
email_server_external_ip: 192.168.1.1
email_users:
- name: foo
password: bar
- name: bar
password: foo
quota: 256
email_domain_zone: foo.bar
cloudflare:
email: [email protected]
api_key: bar
Compatibility
This role is tested on these container images:
container | tags |
---|---|
jrei/systemd-debian | 10 |
SMTP/IMAP connection details
- email:
[email protected]
- server:
smtp.foo.bar
/imap.foo.bar
- username:
foo
- password:
bar
STARTTLS
License
BSD-3-Clause
Install
ansible-galaxy install someone-stole-my-name/ansible-role-email
License
bsd-3-clause
Downloads
37
Owner