Re: Postfix, "From:" address, command line

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Dec 16, 2005 at 15:51:06 +0100,
  Rakotomandimby Mihamina <mihamina.rakotomandimby@xxxxxxxxxxxxxxxxxxx> wrote:
> Hi,
> I sometimes send mail through command line interface this way:
> 
> $ print "short message" | mail -s "your log/pass" test@xxxxxxx
> 
> The problem is the "From:" address: it is a bit ugly.
> I would like to set the "From:" address of that system user to be a more
> esthetic one.
> I am running Fedora Core 4, and postfix-2.2.2 (Fedora build)
> 
> I heard about a file named /etc/mailaddress or something like that but I
> cant find it out on google, or in the archives (I dont remember the
> exact name). I think in that file I just have to fill it like this:
> 
> [...]
> user1 : localpart@xxxxxxx
> [...]
> 
> And then it's OK. But i really lost the file name, and dont know if it
> would be efficient on my Fedora.

You could inject the mail using postfix's injection program. (The equivalent
of sendmail or qmail-inject.) This allows you to include headers along
with the body of the message.
The other option is to use a more powerful mail client such as mutt to send
the message. Something like:
print "short message" | mutt -e 'set from="This is a test <test>"'  -s "your log/pass" test@xxxxxxx


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux