Setting the $ENV{MAILADDRESS} variable allows the Mail::Mailer package to override the default localuser@localhostname. Here's the way I have modified caff to send using my mail server and setting the MAIL FROM:
--- caff.orig 2013-03-02 09:34:18.930745000 -0800 +++ caff 2013-03-02 09:43:31.281814000 -0800 @@ -447,6 +447,18 @@ # Additionally encrypt messages for these keyids #\$CONFIG{'also-encrypt-to'} = [ qw{@keys} ]; +# Mail server settings +# Internet::Mail will pipe to /usr/sbin/sendmail by default. +# To override this and specify SMTP protocol and a server: +# $CONFIG{'mailer-send'} = [ 'smtp', Server => 'mail.domain.com' ]; +# or with SMTP Authentication: +# $CONFIG{'mailer-send'} = [ 'smtp', Server => 'mail.domain.com', +# Auth => ['user', 'pass'] ]; +# The MAIL FROM is constructed from the local user and hostname. +# If your hostname doesn't resolve on the internet, manually +# specify the address that will be used for MAIL FROM: +# $ENV{MAILADDRESS} = 'me\@domain.com'; + -- The total budget at all receivers for solving senders' problems is $0. If you want them to accept your mail and manage it the way you want, send it the way the spec says to. --John Levine -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org