Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Use Postfix (SMTP) server

84 views
Skip to first unread message

Joseph Hesse

unread,
Nov 4, 2012, 3:47:30 PM11/4/12
to
Hi,

I just set up a virtual Postix/Dovecot/MySQL server serving multiple
domains.

The MySQL database has a table of each "user@domain". Each
"user@domain" can receive email sent from an email client.

I read these emails with:
$ mutt -f imaps://user@domain@mail.myserver.com
mutt prompts for a password.

Is there a command line for mutt so I can send email from a
"user@domain" in the database to an arbitrary email address?

Thank you,
Joe


Fredrik Jonson

unread,
Nov 5, 2012, 2:56:16 AM11/5/12
to
Joseph Hesse wrote:

> I just set up a virtual Postix/Dovecot/MySQL server serving multiple
> domains. [...] Is there a command line for mutt so I can send email from
> a "user@domain" in the database to an arbitrary email address?

Do you merely want a different address in the "From" header of the outgoing
mail?

mutt -e 'set realname="Mr Foo";set from=f...@example.org' b...@example.com

If you want the other headers to reflect the user too, you want to configure
the smtp-url, and remember to configure postfix to accept submissions too.

mutt -e 'set smtp_url="smtp://f...@mail.example.org:587/"' ...

And if you do not want to remember these cryptic parameters, a convenient
way to handle multiple identities is mutt's folder hooks.

http://www.mutt.org/doc/manual/manual-3.html#folder-hook

--
Fredrik Jonson
0 new messages