diff --git a/library/roles/postfix/templates/main.cf.j2 b/library/roles/postfix/templates/main.cf.j2 index 38ad03f..d72c317 100644 --- a/library/roles/postfix/templates/main.cf.j2 +++ b/library/roles/postfix/templates/main.cf.j2 @@ -72,12 +72,13 @@ myorigin = {{ ansible_fqdn }} # # Note: you need to stop/start Postfix when this parameter changes. # -{% if not postfix_use_inet_interfaces %} +{% if postfix_use_inet_interfaces %} {% if not postfix_smtpd_server %} inet_interfaces = localhost inet_protocols = ipv4 {% else %} inet_interfaces = {% for int in postfix_inet_interfaces %}{{ int }}{% if not loop.last %}, {% endif %}{% endfor %} + inet_protocols = {% for proto in postfix_inet_protocols %}{{ proto }}{% if not loop.last %}, {% endif %}{% endfor %} {% endif %} {% endif %}