Thanks for your help Rudi!
Ok, one minor issue
I was initially getting the following error:
Mar 12 07:55:05 myhost postfix/pipe[18487]: 85B8DB233EA:
to=<valid#exa...@au...>,
orig_to=<va...@ex...>, relay=vacation, delay=2.1,
delays=0.08/0.19/0/1.8, dsn=5.3.0, status=bounced (Command died with
status 255: "/var/spool/vacation/vacation.pl". Command output: Global
symbol "$my_noreply" requires explicit package name at
/var/spool/vacation/vacation.pl line 589. Missing right curly or square
bracket at /var/spool/vacation/vacation.pl line 627, at end of line
syntax error at /var/spool/vacation/vacation.pl line 627, at EOF
Execution of /var/spool/vacation/vacation.pl aborted due to compilation
errors. )
Adding single quotes around the (true or false) value fixed it.
Also, below note that I changed the variable name (I preferred this to
work differently, hopefully you'll see my logic here), and required it
to be enabled vs disabled to work:
So, instead of a default of
our $send_to_auto = true;
In vacation.pl I now have these defaults:
our $my_noreply = 'false';
#our $my_noreply_pattern =
"bounce|do-not-reply|facebook|linkedin|list-|myspace|twitter"
and in vacation.conf I have
$my_noreply = 'true';
All further tests are poisitive (as expected), so, the new multi-string
test now seems to be fully functional... again, many thanks!
Ok, now, trying to get your new string-as-variable option working (just
defining things in vacation.pl until I get it working there, then will
try moving it to vacation.conf), so that I can define the
$my_noreply_pattern variable...
Just enabling it (not even using it in the actual test module) causes it
to fail with the following error (different from the one above):
Mar 12 08:42:22 myhost postfix/pipe[18940]: D75FCA14AC6:
to=<valid#exa...@au...>,
orig_to=<va...@ex...>, relay=vacation, delay=0.5,
delays=0.16/0.01/0/0.33, dsn=5.3.0, status=bounced (Command died with
status 255: "/var/spool/vacation/vacation.pl". Command output: "my"
variable $subject masks earlier declaration in same scope at
/var/spool/vacation/vacation.pl line 189. "my" variable $messageid masks
earlier declaration in same scope at /var/spool/vacation/vacation.pl
line 190. "my" variable %opts masks earlier declaration in same scope at
/var/spool/vacation/vacation.pl line 194. syntax error at
/var/spool/vacation/vacation.pl line 172, near ") {" Can't use global $0
in "my" at /var/spool/vacation/vacation.pl line 194, near "Usage: $0"
Execution of /var/spool/vacation/vacation.pl aborted due to compilation
errors. )
I tried changing the single quotes to double quotes, ie:
> #our $my_noreply_pattern = "bounce|do-not-reply|facebook|linkedin|list-|myspace|twitter"
But it still fails...
Any ideas?
Thanks again Rudi...
|