ansible-msmtp-mailer/templates/msmtprc.j2

49 lines
1.3 KiB
Plaintext
Raw Normal View History

2014-03-21 19:16:55 +00:00
# {{ ansible_managed }}
# Default settings that all others accounts inherit
2014-03-21 19:16:55 +00:00
defaults
2023-08-20 07:21:28 +00:00
auth {{msmtp_auth}}
tls {{msmtp_tls}}
tls_starttls {{msmtp_tls_starttls}}
2014-06-24 05:43:16 +00:00
{% if msmtp_tls_trust_file is defined %}
tls_trust_file {{msmtp_tls_trust_file}}
{% else %}
2014-03-21 19:16:55 +00:00
tls_trust_file /etc/ssl/certs/ca-certificates.crt
2014-06-24 05:43:16 +00:00
{% endif %}
2014-03-21 19:16:55 +00:00
# Logging
2014-03-21 19:16:55 +00:00
{% if msmtp_log is defined %}
{% if msmtp_log == "syslog" %}
syslog on
{% elif msmtp_log == "file" and msmtp_logfile is defined %}
logfile {{msmtp_logfile}}
{% endif %}
{% endif %}
2018-05-07 08:31:19 +00:00
# default is localhost. Use domain part of your email address or FQDN of host.
domain {{msmtp_domain}}
2018-05-07 08:31:19 +00:00
# default is off. When on, an envelope-from address of the form user@domain will be generated.
2021-05-15 15:20:39 +00:00
auto_from {{msmtp_auto_from}}
# Set a domain part for the generation of an envelope-from address (auto_from)
maildomain {{msmtp_domain}}
# The default is to remove BCC headers.
# remove_bcc_headers on|off
2014-03-21 19:16:55 +00:00
{% if msmtp_accounts is defined %}
{% for msmtp_account in msmtp_accounts %}
#
account {{msmtp_account.account}}
host {{msmtp_account.host}}
port {{msmtp_account.port}}
auth {{msmtp_account.auth}}
from {{msmtp_account.from}}
2014-03-21 19:16:55 +00:00
user {{msmtp_account.user}}
password {{msmtp_account.password}}
{% endfor %}
{% endif %}
# Default account to use
account default : {{msmtp_default_account}}
2014-06-24 05:43:16 +00:00
aliases /etc/aliases