Name

SendMailProgram — sendmail (or compatible) binary location

SYNOPSIS

filename

DESCRIPTION

The directive specifies the location of the sendmail binary (executable file).

DIRECTIVE TYPE AND DEFAULT VALUE

Global directive,
Catalog directive

EXAMPLES

Example: Setting SendMailProgram

SendMailProgram /usr/sbin/sendmail

NOTES

It is not required to specifically use the original sendmail with this directive. Probably all available sendmail replacements include the sendmail binary of their own, but which is completely compatible with the original implementation (regarding command line options).

If this directive is not defined (and none of the defaults are available at startup), it won't be possible to send any e-mails using standard Interchange facilities. In that case, you'll have to pick orders from a tracking file, logs, or some other means.

AVAILABILITY

SendMailProgram is available in Interchange versions:

4.6.0-5.9.0 (git-head)

SOURCE

Interchange 5.9.0:

Source: lib/Vend/Config.pm
Line 436 (context shows lines 426-432)

['SendMailProgram',  'executable',     [
                      $Global::SendMailLocation,
                       '/usr/sbin/sendmail',
                       '/usr/lib/sendmail',
                       'Net::SMTP',
                      ]
                    ],

Source: lib/Vend/Config.pm
Line 606

['SendMailProgram',  'executable',    $Global::SendMailProgram],

Source: lib/Vend/Config.pm
Line 4057 (context shows lines 4057-4113)

sub parse_executable {
my($var, $initial) = @_;
my($x);
my(@tries);

if(ref $initial) {
  @tries = @$initial;
}
else {
  @tries = $initial;
}

TRYEXE:
foreach my $value (@tries) {
#::logDebug("trying $value for $var");
  my $root = $value;
  $root =~ s/\s.*//;

  return $value if $Global::Windows;
  if( ! defined $value or $value eq '') {
    $x = '';
  }
  elsif( $value eq 'none') {
    $x = 'none';
    last;
  }
  elsif( $value =~ /^\w+::[:\w]+\w$/) {
    ## Perl module like Net::SMTP
    eval {
      eval "require $value";
      die if $@;
      $x = $value;
    };
    last if $x;
  }
  elsif ($root =~ m#^/# and -x $root) {
    $x = $value;
    last;
  }
  else {
    my @path = split /:/, $ENV{PATH};
    for (@path) {
      next unless -x "$_/$root";
      $x = $value;
      last TRYEXE;
    }
  }
}
config_error( errmsg(
        "Can't find executable (%s) for the %s directive\n",
        join('|', @tries),
        $var,
        )
  ) unless defined $x;
#::logDebug("$var=$x");
return $x;
}

AUTHORS

Interchange Development Group

SEE ALSO

email(7ic), AsciiTrack(7ic), email-raw(7ic)

DocBook! Interchange!