Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question about structure of postfix_sender_canonicals variable #23

Open
ghost opened this issue Oct 30, 2024 · 0 comments
Open

Question about structure of postfix_sender_canonicals variable #23

ghost opened this issue Oct 30, 2024 · 0 comments

Comments

@ghost
Copy link

ghost commented Oct 30, 2024

The variable is used by the template templates/mapfile.j2. The Template has following structure:

{{ ansible_managed | comment }}

{% for mapping in __postfix_mappings %}
{% for key, value in mapping.items() %}
{{ key }}    {{ value }}
{% endfor %}
{% endfor %}

The question is, why is it a list of dict keys, which should be unique?
Currently you could do something like this:

postfix_sender_canonicals:
  - root: test1@example.com
  - root: test2@example.com

Which would result in:

root      test1@example.com
root      test2@example.com

If the variable would be a single dictionary, such thing would not be possible because a dict can not have two keys with the same name.

So the question is, why is it implemented as a list?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

0 participants