mjl- / mox

modern full-featured open source secure mail server for low-maintenance self-hosted email
https://www.xmox.nl
MIT License
3.38k stars 89 forks source link

Recommended self-hosting mailing list solution that meshes well with mox? #99

Open naturalethic opened 7 months ago

naturalethic commented 7 months ago

As this feature is not on the roadmap, can anyone reading this offer up any suggestion for self-hosted mailing list options that would go well with mox?

naturalethic commented 7 months ago

To be clear, I don't want to do marketing mails, I want to set up aliases that have a group of recipients, for incoming mail. Perhaps this is better called 'groups' ? Maybe this feature must be built in.

mjl- commented 7 months ago

It would be interesting to see what it would take to get mailman working with mox. I think mailman is the most popular open source mailing list manager. It may be a bit overkill for small-scale/private use though. A mailing list manager isn't on the roadmap, but depending on how much work it is (to build and maintain), I would be interested in having some (basic) mailing list manager implementation in mox. It's just that mox already has a rather large todo-list... (: So, ideas and experiences with existing software welcome.

naturalethic commented 7 months ago

Does mox have an LMTP interface?

mjl- commented 7 months ago

Does mox have an LMTP interface?

No, not currently. Is mailing list manager software requiring it, with regular SMTP not an option? LMTP doesn't seem very different from SMTP. We could implement it in mox. But I noticed this in RFC 2033:

A server implementation which is capable of quickly accepting responsibility for delivering or relaying a message to multiple recipients and which is capable of sending any necessary notification messages SHOULD NOT implement the LMTP protocol.

The upside of LMTP is that the submitter can receive immediate feedback of delivery, without having to wait for/process a DSN. But mailing list managers will have to implement processing DSN's anyway, so I don't yet see why LMTP would be required (other than that SMTP is simply not implemented).

naturalethic commented 7 months ago

From mailman docs:

Mailman accepts incoming messages from the MTA using the Local Mail Transfer Protocol (LMTP) interface. LMTP is much more efficient than spawning a process just to do the delivery. Most open source MTAs support LMTP for local delivery. If yours doesn’t, and you need to use a different interface, please ask on the mailing list or on IRC.

Mailman passes all outgoing messages to the MTA using the Simple Mail Transfer Protocol (SMTP).

mjl- commented 7 months ago

ah, lmtp for delivery, not accepting email. that makes sense. mox doesn't yet support delivery to anything outside mox. for delivering to outside mox, i had considered writing to mbox (annoying due to different file locking mechanisms), maildirs (could be done), and by executing processes (seems (security) error prone). the option of delivering to lmtp wasn't on my radar, and seems niche, but shouldn't be too hard to implement because most of the building blocks (code) are there. if you think adding this will allow running a mailing list through mox, i could add support for lmtp delivery.

naturalethic commented 7 months ago

Ok, well for me what I'm really looking for is just being able to set up groups, and have that group be addressable by an alias, where each member gets a copy. I don't really care which mechanism. Ideally I'd prefer not to have to run another service, but if LMTP is the simplest approach and fits the scope of mox, I can run mailman, or anything similar, perhaps some simple custom thing of my own.

mjl- commented 7 months ago

are these the members of the group all local users, on the same mox instance? in that case, it would be similar to issue #57.

if you want to send messages to external addresses, you may need mailing list software to make it all work. especially when you want to send to external addresses in combination with dmarc, you cannot always just deliver copies of messages to other addresses. whether simple copying would work depends on the addresses that can send to the list/alias, and the recipient addresses (members), and how their mail servers are configured. if simple copying doesn't work, you'll have to rewrite at least the From header. that's something that mailing list software would do for you.

running a mailman instance for a small group feels like it may be a bit much for just a 5 people...

naturalethic commented 7 months ago

Yep only to local users, so #57 does cover it. I scanned the issues but somehow didn't register that one. I could probably wire up simple smtp client + command line import call to implement my needs in the very short term, letting you puzzle out the best long term solution.