Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'postfix null client' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
postfix null client
Authored by: gshenaut on Sep 29, '05 08:38:03PM

I don't need a full-service postfix mail server, but I do want to be able to send mail out from scripts, etc. To do this, I edited two files in /etc/postfix: main.cf and master.cf. In main.cf, I set "myorigin" to the host I wanted outgoing mail to be from; "relayhost" to the actual mail server that will send the mail (it must be willing to relay mail from you, obviously). "local_transport" is set to the string "error:local delievery is disabled". In master.cf, I commented out the entries for "SMTP server" and "local delivery agent". Note that there are no doublequotes in the actual files, I just used them here for clarity.

Note that I only use this inside our local network, this is why I don't have to fiddle with authentication and why the relayhost will relay my mail. If you want a more general null client that will work in any location with authenticating SMTP server, it will be more complicated. Also, if you want to receive mail with postfix, it will be more complicated.

Anyway, if I am remembering this correctly, once you edit those files, you can send mail with mail(1). Actually, it may work for most people out of the box, maybe my set-up is strange. I wouldn't know.

Greg Shenaut



[ Reply to This | # ]