Added sendmail::client::msa for sending mail using submission port
This commit is contained in:
parent
3f1bb7a278
commit
ca0427624b
4 changed files with 32 additions and 25 deletions
|
@ -47,28 +47,24 @@ class sendmail::client inherits sendmail::common {
|
|||
$mail_server = "127.0.0.1"
|
||||
}
|
||||
|
||||
case $operatingsystem {
|
||||
"openbsd": {
|
||||
file { "/usr/share/sendmail/cf/submit.mc":
|
||||
ensure => present,
|
||||
content => template("sendmail/submit.mc.erb"),
|
||||
owner => "root",
|
||||
group => "bin",
|
||||
mode => 0444,
|
||||
notify => Exec["make submit.cf"],
|
||||
}
|
||||
}
|
||||
default: {
|
||||
file { "/etc/mail/submit.mc":
|
||||
path => $operatingsystem ? {
|
||||
"openbsd" => "/usr/share/sendmail/cf/submit.mc",
|
||||
default => "/etc/mail/submit.mc",
|
||||
},
|
||||
ensure => present,
|
||||
content => template("sendmail/submit.mc.erb"),
|
||||
content => template("sendmail/submit.mc.erb", "sendmail/submit.mc.msp.erb"),
|
||||
owner => "root",
|
||||
group => "root",
|
||||
group => $operatingsystem ? {
|
||||
"openbsd" => "bin",
|
||||
default => "root",
|
||||
},
|
||||
mode => 0644,
|
||||
notify => Exec["make submit.cf"],
|
||||
require => Package["sendmail"],
|
||||
}
|
||||
}
|
||||
require => $operatingsystem ? {
|
||||
"openbsd" => undef,
|
||||
default => Package["sendmail"],
|
||||
},
|
||||
}
|
||||
|
||||
exec { "make submit.cf":
|
||||
|
@ -102,6 +98,18 @@ class sendmail::client inherits sendmail::common {
|
|||
|
||||
}
|
||||
|
||||
|
||||
# Configure Sendmail submission using port 587.
|
||||
#
|
||||
class sendmail::client::msa inherits sendmail::client {
|
||||
|
||||
File["/etc/mail/submit.mc"] {
|
||||
content => template("sendmail/submit.mc.erb", "sendmail/submit.mc.msa.erb"),
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
# Configure Sendmail server.
|
||||
#
|
||||
# $sendmail_domain:
|
||||
|
|
|
@ -35,6 +35,3 @@ define(`confDOMAIN_NAME', `<%= mail_domain %>')dnl
|
|||
define(`confPID_FILE', `/var/run/sm-client.pid')dnl
|
||||
<% end -%>
|
||||
FEATURE(`use_ct_file')dnl
|
||||
dnl
|
||||
dnl If you use IPv6 only, change [127.0.0.1] to [IPv6:::1]
|
||||
FEATURE(`msp', `[<%= mail_server %>]')dnl
|
||||
|
|
1
sendmail/templates/submit.mc.msa.erb
Normal file
1
sendmail/templates/submit.mc.msa.erb
Normal file
|
@ -0,0 +1 @@
|
|||
FEATURE(`msp', `[<%= mail_server %>]', `MSA')dnl
|
1
sendmail/templates/submit.mc.msp.erb
Normal file
1
sendmail/templates/submit.mc.msp.erb
Normal file
|
@ -0,0 +1 @@
|
|||
FEATURE(`msp', `[<%= mail_server %>]')dnl
|
Loading…
Add table
Reference in a new issue