chore(main.cf): Add note advising caution changing mydestination#3316
Merged
casperklein merged 3 commits intomasterfrom May 10, 2023
Merged
Conversation
Changing the Postfix `mydestination` setting is fragile. Review feedback and insights documented for maintainers to be aware of have been linked besides this config setting. Should a change be proposed again for `mydestination`, it is clear that it has a wider impact to keep in mind than it may originally appear to for DMS.
georglauterbach
approved these changes
May 10, 2023
Member
Author
|
@georglauterbach I figured this was a better location than a page or FAQ entry in the docs which'd probably have less visibility to those wanting to actually contribute a PR to change it. |
Member
Agreed 👍🏼 |
8 tasks
casperklein
approved these changes
May 10, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Changing the Postfix
mydestinationsetting is fragile. Review feedback and insights have been linked in themain.cfconfig as a way to document awareness of this information better to maintainers/contributors in future.Should a change be proposed again for
mydestination, it is clear that it has a wider impact to keep in mind than it may originally appear to for DMS.#3264 proposed modifying
mydestination, but was decided that there was too much to take into consideration for an improvement.mail.example.com)localhostcould be used, and some related changes were considered. However that would affect the address Postfix used for sending mail from (MAILER-DAEMON@localhost), which would be problematic. System mail and aliases also came into consideration.mydestinationwould be an improvement without regressions.Thus the current behaviour difference remains (neither ideal):
mydestinationis no longer configured to recognize local mail, the local aliases foramavis,root,clamav, etc would not resolve to local delivery. Setting virtual alias recipients should work, but is not ideal at creating a distinction between user and system accounts/aliases:/etc/aliasesmay not be checked due tomydestinationnot matching (eg: Postfix sender address is[email protected],@example.comis configured as vhost and thus queries Dovecot if no virtual alias was set).postmaster, since that would accept any recipient address matching, virtual aliases apply not only to inbound mail recipients, but also outbound recipients IIRC.mail.example.com) will allow managing mail forexample.comvia virtual alias domain just like with bare domain setup. However,mydestinationwill represent the DMS MTA itself, recognizing mail destined to the DMS FQDN as specifically for that purpose. Typically this is just for system accounts (from/etc/passwd) to notify the postmaster/admin, and the/etc/aliasesto add additional accounts likepostmasterthat will accept mail when the local part of the recipient address matches (with the domain part qualifying as a match tomydestination). If an alias is not added to forward that mail to an actual mailbox however, Postfix will deliver it to/var/mail/usernamein a mailbox file which Dovecot will not be aware of.Type of change
Checklist: