ansible-role-postfix/templates/postfix/conf.d/virtual_aliases
2023-03-24 15:42:15 +01:00

27 lines
556 B
Text

# {{ ansible_managed }}
# Example
#
# postfix_aliases:
# - domain:
# name: mydomain.org
# comment: |
# # Mydomain.org
# # List of Aliases
# aliases:
# - name: foo
# dest:
# - "alice@yourdomain.org
{% if postfix_aliases is defined %}
{% for domain in postfix_aliases %}
### {{ domain.name}}
{% if domain.comment is defined %}
{{ domain.comment }}
{% endif %}
{% for alias in domain.aliases %}
{{ "%-50s %s" | format(alias.name + '@' + domain.name, alias.dest | join(',')) }}
{% endfor %}
{% endfor %}
{% endif %}