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



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

--
fedora-list mailing list
fedora-list@xxxxxxxxxx
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list



Relevant Pages

  • Re: dynamic type checking - a pauline conversion?
    ... >> defined in an interface, if they dont, then my original point applies. ... > Paul C wrote: ... > "If they dont share any commonality then then surely there is ... If there is no interface overlap then you have to explicitly switch on object type ...
    (comp.object)
  • Passing arrays from VB6 to C# ActiveX
    ... dont get the list of availbale member functions in VB but the code WORKS. ... getting the following error message "Function or interface marked as ... Use in the declaration in C# code. ... The type library file looks ...
    (microsoft.public.dotnet.framework.interop)
  • Re: US/UK dates problem
    ... The article explains how Access uses your Regional Settings in the ... interface, but expects the American format delimited with # for literal ... dates in SQL statements and VBA. ... I dont think the system date could have changed as its a work computer ...
    (comp.databases.ms-access)
  • Re: sun gigabit ethernet (ge) issues
    ... number of stats coming across the interface. ... >> We've been seeing some weirdness on one of our nfs clusters with ... We dont see any evidence of the issue on our switches. ... Justin Shaffer ...
    (comp.sys.sun.hardware)
  • Re: php-mysql
    ... >> login as root and give the following command ... > you could use apache2 but then I dont know where the config files are ... > I dont know which distribution you use, but in Debian Etch the files are ... server will only work on the server console till you tweek ...
    (Debian-User)