In my time I have configured and worked with smail, sendmail, qmail and postfix.
But my need is pretty simple and I’d prefer not getting into the all the configuration details of the above tools.
I just need “something” that listens at port 25, acting as a SMTP daemon, and allows me to process each arriving message with a script (bash, python, perl, php, nodejs, whatever…)
Using the .forward+procmail solution would be an option but, besides those being unmaintained tools, I’d still have to have an STMP daemon (one of the above) and would have to do that configuration for each user which would be a lot of work and besides the point since I actually dont intend to have “users”.
What I want to do is to be able to receive email for any XXXX@domain.tld address and be able to process the message whatever XXXX is, parse its contents and “ship” them to whatever destination (file, table, database, /dev/null….)
Currently looking at https://www.opensmtpd.org/ as best option.