Version information
This version is compatible with:
- Puppet Enterprise 2023.8.x, 2023.7.x, 2023.6.x, 2023.5.x, 2023.4.x, 2023.3.x, 2023.2.x, 2023.1.x, 2023.0.x, 2021.7.x, 2021.6.x, 2021.5.x, 2021.4.x, 2021.3.x, 2021.2.x, 2021.1.x, 2021.0.x
- Puppet >= 7.0.0 < 9.0.0
- , , , ,
Start using this module
Add this module to your Puppetfile:
mod 'stm-sendmail', '4.1.0'
Learn more about managing modules with a PuppetfileDocumentation
sendmail
Table of Contents
- Overview
- Module Description - What the module does and why it is useful
- Setup - The basics of getting started with sendmail
- Usage - Configuration options and additional functionality
- Reference - An under-the-hood peek at what the module is doing and how
- Limitations - OS compatibility, etc.
- Development - Guide for contributing to the module
Overview
Install and manage the Sendmail MTA.
Module Description
Sendmail is a powerful mail transfer agent, and this modules provides an easier way to generate and manage the main Sendmail configuration files /etc/mail/sendmail.mc
and /etc/mail/submit.mc
. It also manages entries in various Sendmail database files (e.g. /etc/mail/access
and /etc/mail/mailertable
).
Setup
What sendmail affects
- The module installs the operating system package to run the Sendmail MTA and possibly some other packages (make, m4, ...) to support it.
- In a default installation almost all the managed files are in the
/etc/mail
directory. A notably exception is the/etc/aliases
file. - The module may generate a new
/etc/mail/sendmail.mc
which is the source for/etc/mail/sendmail.cf
. This file is the main Sendmail configuration file and it affects how Sendmail operates.
WARNING: Make sure to understand and test everything in these files before putting it in production. You alone are accountable for deploying a safe mailer configuration. If you do not know how to configure Sendmail without this module, then you should not assume you can do it with it.
Setup Requirements
The sendmail module uses a custom Augeas lense so the Puppet configuration setting pluginsync
must be enabled. It also requires the Puppetlabs modules stdlib
, concat
, augeas_core
and mailalias_core
.
Beginning with Sendmail
Declare the Sendmail class to install and run Sendmail with the default parameters.
class { 'sendmail': }
This installs the necessary packages and starts the Sendmail service. With this setup Sendmail will send messages to other hosts and also accept mail for the local host.
Sendmail has a lot of configuration knobs and a complete setup may need more than just a few parameters. So it is probably a good idea to encapsulate your Sendmail settings by using the roles and profiles pattern.
Usage
The Sendmail module provides classes and defined types to individually manage many of the configuration parameters used in the sendmail.mc
file. This offers the possibility to manage even complex and unusual configurations with Puppet. The main Sendmail class also has parameters to directly enable certain configuration items without the need to provide a complete user defined sendmail.mc
configuration.
I need a couple of macros and features in my Sendmail setting
Normally the configuration of Sendmail is done by adding define
statements to the main sendmail.mc
configuration file. The m4
macro processor is used to convert the settings into a sendmail.cf
file that Sendmail understands.
The same mechanism is used to add features like greylisting, virtual user setups or DNS blacklists. Sendmail uses the feature
statement in the sendmail.mc
configuration to enable the features.
With the Sendmail module these settings are defined by adding resources using the sendmail::mc::define
or sendmail::mc::feature
defined types.
# Manage Sendmail and set a smart host and the maximum message size
class { 'sendmail':
smart_host => 'relay.example.com',
max_message_size => '32MB',
}
# Set maximum number of daemon processes
sendmail::mc::define { 'confMAX_DAEMON_CHILDREN':
expansion => '8',
}
# Include ratecontrol feature with parameters
sendmail::mc::feature { 'ratecontrol':
args => [ 'nodelay', 'terminate', ],
}
# Enable access_db feature
sendmail::mc::feature { 'access_db': }
# Manage access_db entries in hiera
class { 'sendmail::access': }
# Manage aliases file using a template
class { 'sendmail::aliases':
content => template('site/aliases.erb'),
}
See REFERENCE.md
for the complete list of available types that can be used.
Most hosts do not need to receive mail
Use the sendmail::nullclient
class to create a setup where no mail can be received from the outside and all local mail is forwarded to a central mail hub. This configuration is appropriate for the majority of satellite hosts.
class { 'sendmail::nullclient':
mail_hub => '[192.168.1.1]',
}
I already have a working config and like to keep it
Disable the internal management of the sendmail configuration files by setting the parameters manage_sendmail_mc
or manage_submit_mc
to false
:
class { 'sendmail':
manage_sendmail_mc => false,
manage_submit_mc => false,
}
Note: These settings also disable the automatic generation of the
sendmail.cf
andsubmit.cf
files. You will have to do that yourself if you change one of the files.
I am behind a firewall and need to forward outgoing mail to a relay host
Use the smart_host
parameter to set the host where all outgoing mail should be forwarded to.
class { 'sendmail':
smart_host => 'relay.example.com',
}
I have a host that should not receive any mail from the outside
You can use the enable_ipv4_daemon
and enable_ipv6_daemon
parameters to prevent Sendmail from listening on all available network interfaces. Use the sendmail::mc::daemon_options
defined type to explicitly define the addresses to use.
class { 'sendmail':
enable_ipv4_daemon => false,
enable_ipv6_daemon => false,
}
sendmail::mc::daemon_options { 'MTA-v4':
addr => '127.0.0.1',
family => 'inet',
port => 'smtp',
}
Transport layer encryption (TLS) is a must in my setup
The Sendmail class has a comprehensive set of TLS related parameters. The following configuration creates a simple TLS enabled setup. Remember to adjust the pathnames to your setup.
class { 'sendmail':
ca_cert_file => '/etc/mail/tls/my-ca-cert.pem',
server_cert_file => '/etc/mail/tls/server.pem',
server_key_file => '/etc/mail/tls/server.key',
client_cert_file => '/etc/mail/tls/server.pem',
client_key_file => '/etc/mail/tls/server.key',
cipher_list => 'HIGH:!MD5:!eNULL',
}
Note: The Sendmail module does not manage any X.509 certificates or keys.
All my users are managed using LDAP
A complex configuration like this is supported by using the provided defined types as building blocks. The following example configuration reflects a setup that is actually in use.
sendmail::mc::define { 'confLDAP_CLUSTER':
expansion => 'example.net',
}
sendmail::mc::define { 'confLDAP_DEFAULT_SPEC':
expansion => '-H ldapi:/// -w 3 -b dc=example,dc=net',
}
sendmail::mc::ldaproute_domain { 'example.net': }
$ldap_filter = '(&(objectClass=inetLocalMailRecipient)(mailLocalAddress=%0))'
sendmail::mc::feature { 'ldap_routing':
args => [
"ldap -1 -T<TMPF> -v mailHost -k ${ldap_filter}",
"ldap -1 -T<TMPF> -v mailRoutingAddress -k ${ldap_filter}",
'bounce',
'preserve',
'nodomain',
'tempfail',
]
}
sendmail::mc::feature { 'virtusertable':
args => "ldap -1 -T<TMPF> -v uid -k ${ldap_filter}",
}
Reference
See the included REFERENCE.md
.
Limitations
The Sendmail module is currently developed and tested on:
- Debian 11 (Bullseye)
Development
Sendmail is a powerful tool with many configuration options. The module includes configuration options I considered useful or needed for my own environment.
You may open Github issues for this module if you need additional configuration file options currently not available.
Feel free to send pull requests for new features.
Reference
Table of Contents
Classes
Public Classes
sendmail
: Manage the Sendmail MTA.sendmail::access
: Manage the Sendmail access db file.sendmail::access::file
: Manage the Sendmail access db file.sendmail::aliases
: Manage the Sendmail aliases file.sendmail::aliases::file
: Create the Sendmail aliases file.sendmail::authinfo
: Manage the Sendmail authinfo db file.sendmail::authinfo::file
: Create the Sendmail authinfo db file.sendmail::domaintable
: Manage the Sendmail domaintable db file.sendmail::domaintable::file
: Manage the Sendmail domaintable db file.sendmail::genericstable
: Manage the Sendmail genericstable db file.sendmail::genericstable::file
: Manage the Sendmail genericstable db file.sendmail::mailertable
: Manage the Sendmail mailertable db file.sendmail::mailertable::file
: Manage the Sendmail mailertable db file.sendmail::makeall
: Rebuild all config files for the Sendmail MTA using a Makefilesendmail::mc::privacy_flags
: Manage privacy flags for the Sendmail MTAsendmail::mc::timeouts
: Manage various timeout settings in the 'sendmail.mc' file.sendmail::mc::trust_auth_mech
: Add theTRUST_AUTH_MECH
macro to the sendmail.mc file.sendmail::nullclient
: Create a simple Sendmail nullclient configuration.sendmail::userdb
: Manage the Sendmail userdb db file.sendmail::userdb::file
: Manage the Sendmail userdb file.sendmail::virtusertable
: Manage the Sendmail virtusertable db file.sendmail::virtusertable::file
: Manage the Sendmail virtusertable db file.
Private Classes
sendmail::aliases::newaliases
: Rebuild the Sendmail aliases file.sendmail::local_host_names
: Manage entries in the Sendmail local-host-names file.sendmail::mc
: Manage the sendmail.mc filesendmail::mc::define_section
: Add a section header to improve readability of the config filesendmail::mc::enhdnsbl_section
: Add a section header to improve readability of the config filesendmail::mc::feature_section
: Add a section header to improve readability of the config filesendmail::mc::ldap_section
: Add a section header above the ldap settingssendmail::mc::local_config_section
: Add a section header to improve readability of the config filesendmail::mc::macro_section
: Add a section header to improve readability of the config filesendmail::mc::mailer_section
: Add a section header to improve readability of the config filesendmail::mc::milter_section
: Add a section header to improve readability of the config filesendmail::mc::queue_group_section
: Add a section header to improve readability of the config filesendmail::mc::starttls
: ManageSTARTTLS
parameters in the 'sendmail.mc' file.sendmail::package
: Manage the Sendmail MTA package.sendmail::params
: The parameters used when setting up the Sendmail MTA.sendmail::relay_domains
: Manage entries in the Sendmail relay-domains file.sendmail::service
: Manage the Sendmail service.sendmail::submit
: Manage the submit.mc file for the Sendmail submission program.sendmail::trusted_users
: Manage entries in the Sendmail trusted-users file.
Defined types
sendmail::access::entry
: Manage an entry in the Sendmail access db file.sendmail::aliases::entry
: Manage an entry in the Sendmail alias file.sendmail::authinfo::entry
: Manage an entry in the Sendmail authinfo db file.sendmail::domaintable::entry
: Manage an entry in the Sendmail domaintable file.sendmail::genericstable::entry
: Manage an entry in the Sendmail genericstable file.sendmail::mailertable::entry
: Manage an entry in the Sendmail mailertable file.sendmail::mc::daemon_options
: Add theDAEMON_OPTIONS
macro to the sendmail.mc file.sendmail::mc::define
: Add m4 macro defines to the sendmail.mc file.sendmail::mc::domain
: Add theDOMAIN
macro to the sendmail.mc file.sendmail::mc::enhdnsbl
: Manage enhanced DNS blacklist entriessendmail::mc::feature
: Add theFEATURE
macro to the sendmail.mc file.sendmail::mc::generics_domain
: Add theGENERICS_DOMAIN
macro to the sendmail.mc file.sendmail::mc::include
: Add include fragments to the sendmail.mc file.sendmail::mc::ldaproute_domain
: Add theLDAPROUTE_DOMAIN
macro to the sendmail.mc file.sendmail::mc::local_config
: Add aLOCAL_CONFIG
section into the sendmail.mc file.sendmail::mc::mailer
: Add aMAILER
macro to the sendmail.mc file.sendmail::mc::masquerade_as
: Add theMASQUERADE_AS
macro to the sendmail.mc file.sendmail::mc::milter
: Manage Sendmail Milter configuration in sendmail.mcsendmail::mc::modify_mailer_flags
: Add aMODIFY_MAILER_FLAGS
macro to the sendmail.mc file.sendmail::mc::ostype
: Add theOSTYPE
macro to the sendmail.mc file.sendmail::mc::queue_group
: Add theQUEUE_GROUP
macro to the sendmail.mc file.sendmail::mc::versionid
: Add theVERSIONID
macro to the sendmail.mc file.sendmail::mc::virtuser_domain
: Add theVIRTUSER_DOMAIN
macro to the sendmail.mc file.sendmail::userdb::entry
: Manage an entry in the Sendmail userdb file.sendmail::virtusertable::entry
: Manage an entry in the Sendmail virtusertable db file.
Functions
sendmail::canonify_array
: Canonify an array
Data types
Sendmail::DHParam
: The valid number of bits for DH params.Sendmail::Deliverymode
: The supported delivery modes for Sendmail.Sendmail::Loglevel
: The supported loglevels.Sendmail::Messagesize
: A message size specification in bytes, kb or Mb.Sendmail::Timeout
: A timeout specification in seconds or minutes.
Classes
sendmail
Perform the basic setup and installation of Sendmail on the system.
Examples
class { 'sendmail': }
Parameters
The following parameters are available in the sendmail
class:
smart_host
domain_name
max_message_size
log_level
dont_probe_interfaces
features
enable_ipv4_daemon
enable_ipv6_daemon
mailers
local_host_names
relay_domains
trusted_users
trust_auth_mech
ca_cert_file
ca_cert_path
server_cert_file
server_key_file
client_cert_file
client_key_file
server_cert_file2
server_key_file2
client_cert_file2
client_key_file2
crl_file
dh_params
tls_srv_options
cipher_list
server_ssl_options
client_ssl_options
cf_version
version_id
msp_host
msp_port
enable_msp_trusted_users
manage_sendmail_mc
manage_submit_mc
auxiliary_packages
package_ensure
package_manage
service_name
service_enable
service_manage
service_ensure
service_hasstatus
smart_host
Data type: Optional[String]
Servers that are behind a firewall may not be able to deliver mail directly to the outside world. In this case the host may need to forward the mail to the gateway machine defined by this parameter. All nonlocal mail is forwarded to this gateway.
Default value: undef
domain_name
Data type: Optional[String]
Sets the official canonical name of the local machine.
Normally this parameter is not required as Sendmail uses the fully
qualified domain name by default. Setting this parameter will override
the value of the $j
macro in the sendmail.cf file.
Default value: undef
max_message_size
Data type: Optional[String]
Define the maximum message size that will be
accepted. This can be a pure numerical value given in bytes
(e.g. 33554432) or a number with a prefixed byte unit (e.g. 32MB). The
conversion is done using the 1024 convention (see the to_bytes
function
in the stdlib
module), so valid prefixes are either k
for 1024 bytes
or M
for 1048576 bytes.
Default value: undef
log_level
Data type: Optional[Sendmail::Loglevel]
The loglevel for the sendmail process. Valid options: a numeric value.
Default value: undef
dont_probe_interfaces
Data type: Optional[Boolean]
Sendmail normally probes all network
interfaces to get the hostnames that the server may have. These
hostnames are then considered local. This option can be used to prevent
the reverse lookup of the network addresses. If this option is set to
localhost
then all network interfaces except for the loopback interface
is probed. Valid options: the strings true
, false
or localhost
.
Default value: undef
features
Data type: Hash[String,Data]
A hash of features to include in the configuration. Each
hash key should be a feature name while the value should be a hash
itself. The value hash is used as parameters for the
sendmail::mc::feature
defined type. Check the documentation of this
type for details.
Some features (e.g. mailertable
, access_db
, ...) may need to be
managed individually. So the mailertable
feature could be enabled using
this parameter but that does not manage the mailertable file itself. So
in addition you would have to use the sendmail::mailertable
class or
the sendmail::mailertable::entry
defined type.
Default value: {}
enable_ipv4_daemon
Data type: Boolean
Should the host accept mail on all IPv4 network
adresses. Valid options: true
or false
.
Default value: true
enable_ipv6_daemon
Data type: Boolean
Should the host accept mail on all IPv6 network
adresses. Valid options: true
or false
.
Default value: true
mailers
Data type: Array[String]
An array of mailers to add to the configuration. The
default is [ 'smtp', 'local' ]
.
Default value: $sendmail::params::mailers
local_host_names
Data type: Array[String]
An array of hostnames that Sendmail considers for a local delivery.
Default value: [$facts['networking']['fqdn']]
relay_domains
Data type: Array[String]
An array of domains that Sendmail accepts as relay target. This setting is required for secondary MX setups.
Default value: []
trusted_users
Data type: Array[String]
An array of user names that will be written into the trusted users file. Leading or trailing whitespace is ignored. Empty entries are also ignored.
Default value: []
trust_auth_mech
Data type: Optional[Variant[String,Array[String]]]
The value of the TRUST_AUTH_MECH
macro to set. If
this is a string it is used as-is. For an array the value will be
concatenated into a string.
Default value: undef
ca_cert_file
Data type: Optional[Stdlib::Absolutepath]
The filename of the SSL CA certificate.
Default value: undef
ca_cert_path
Data type: Optional[Stdlib::Absolutepath]
The directory where SSL CA certificates are kept.
Default value: undef
server_cert_file
Data type: Optional[Stdlib::Absolutepath]
The filename of the SSL server certificate for inbound connections.
Default value: undef
server_key_file
Data type: Optional[Stdlib::Absolutepath]
The filename of the SSL server key for inbound connections.
Default value: undef
client_cert_file
Data type: Optional[Stdlib::Absolutepath]
The filename of the SSL client certificate for outbound connections.
Default value: undef
client_key_file
Data type: Optional[Stdlib::Absolutepath]
The filename of the SSL client key for outbound connections.
Default value: undef
server_cert_file2
Data type: Optional[Stdlib::Absolutepath]
The filename of the secondary SSL server
certificate for inbound connections. The parameter is only valid on
Sendmail 8.15.1 or later and when server_cert_file
is set.
Default value: undef
server_key_file2
Data type: Optional[Stdlib::Absolutepath]
The filename of the secondary SSL server key for
inbound connections. The parameter is only valid on Sendmail 8.15.1 or
later and when server_key_file
is set.
Default value: undef
client_cert_file2
Data type: Optional[Stdlib::Absolutepath]
The filename of the secondary SSL client
certificate for outbound connections. The parameter is only valid on
Sendmail 8.15.1 or later and when client_cert_file
is set.
Default value: undef
client_key_file2
Data type: Optional[Stdlib::Absolutepath]
The filename of the secondary SSL client key for
outbound connections. The parameter is only valid on Sendmail 8.15.1 or
later and when client_key_file
is set.
Default value: undef
crl_file
Data type: Optional[Stdlib::Absolutepath]
The filename with a list of revoked certificates.
Default value: undef
dh_params
Data type: Optional[Sendmail::DHParam]
The DH parameters used for encryption. This can be one of
the numbers 512
, 1024
, 2048
or a filename with generated
parameters.
Default value: undef
tls_srv_options
Data type: Optional[Enum['V','']]
The parameter adjusts the server TLS settings. This
can currently be either the letter V
or the empty string. Setting this
parameter to V
disables the request for a client certificate.
Default value: undef
cipher_list
Data type: Optional[String]
Set the available ciphers for encrypted connections.
Default value: undef
server_ssl_options
Data type: Optional[String]
Configure the SSL connection flags for inbound connections.
Default value: undef
client_ssl_options
Data type: Optional[String]
Configure the SSL connection flags for outbound connections.
Default value: undef
cf_version
Data type: Optional[String]
The configuration version string for Sendmail. This
string will be appended to the Sendmail version in the HELO
message.
If unset, no configuration version will be used.
Default value: undef
version_id
Data type: Optional[String]
The version id string included in the sendmail.mc file. This has no practical meaning other than having a used defined identifier in the file.
Default value: undef
msp_host
Data type: String
The host where the message submission program should
deliver to. This can be a hostname or IP address. To prevent MX lookups
for the host, put it in square brackets (e.g., [hostname]
). Delivery
to the local host would therefore use either [127.0.0.1]
for IPv4 or
[IPv6:::1]
for IPv6.
Default value: '[127.0.0.1]'
msp_port
Data type: Pattern[/^(MSA)|([0-9]+)$/]
The port used for the message submission program. Can be
a port number (e.g., 25
) or the literal MSA
for delivery to the
message submission agent on port 587.
Default value: 'MSA'
enable_msp_trusted_users
Data type: Boolean
Whether the trusted users file feature is
enabled for the message submission program. This may be necessary if you
want to allow certain users to change the sender address using sendmail -f
. Valid options: true
or false
.
Default value: false
manage_sendmail_mc
Data type: Boolean
Whether to automatically manage the sendmail.mc
file. Valid options: true
or false
.
Default value: true
manage_submit_mc
Data type: Boolean
Whether to automatically manage the submit.mc
file. Valid options: true
or false
.
Default value: true
auxiliary_packages
Data type: Array[String]
Additional packages that will be installed by the Sendmail module. Valid options: array of strings. The default varies by operating system.
Default value: $sendmail::params::auxiliary_packages
package_ensure
Data type: String
Configure whether the Sendmail package should be
installed, and what version. Valid options: present
, latest
, or
a specific version number.
Default value: 'present'
package_manage
Data type: Boolean
Configure whether Puppet should manage the Sendmail
package(s). Valid options: true
or false
.
Default value: $sendmail::params::package_manage
service_name
Data type: String
The service name to use on this operating system.
Default value: $sendmail::params::service_name
service_enable
Data type: Boolean
Configure whether the Sendmail MTA should be enabled
at boot. Valid options: true
or false
.
Default value: true
service_manage
Data type: Boolean
Configure whether Puppet should manage the Sendmail
service. Valid options: true
or false
.
Default value: true
service_ensure
Data type: Stdlib::Ensure::Service
Configure whether the Sendmail service should be
running. Valid options: running
or stopped
.
Default value: 'running'
service_hasstatus
Data type: Boolean
Define whether the service type can rely on
a functional status. Valid options: true
or false
.
Default value: true
sendmail::access
The class manages the file either as a single file resource or each entry
in the file separately. The file is managed as a whole using the source
or content
parameters. The entries
parameter is used to manage each
entry separately. Preferable this is done with hiera using automatic
parameter lookup.
This class is only used to manage the access db file. You will also need to
enable the access_db
feature using sendmail::mc::feature
to tell
Sendmail to actually use the file.
Examples
Manage the access database using hiera
class { 'sendmail::access': }
Manage the access database using the given file
class { 'sendmail::access':
source => 'puppet:///modules/sendmail/access',
}
Parameters
The following parameters are available in the sendmail::access
class:
content
Data type: Optional[String]
The desired contents of the access file. This allows
managing the access file as a whole. Changes to the file automatically
triggers a rebuild of the access database file. This attribute is
mutually exclusive with source
and entries
.
Default value: undef
source
Data type: Optional[String]
A source file for the access file. This allows managing the
access file as a whole. Changes to the file automatically triggers
a rebuild of the access database file. This attribute is mutually
exclusive with content
and entries
.
Default value: undef
entries
Data type: Hash[String,Data]
A hash that will be used to create sendmail::access::entry
resources. The class can be used to create access entries defined in
hiera. The hiera hash should look like this:
sendmail::access::entries:
'example.com':
value: 'OK'
'example.org':
value: 'REJECT'
Default value: {}
sendmail::access::file
Manage the Sendmail access db file.
Examples
class { 'sendmail::access::file': }
Parameters
The following parameters are available in the sendmail::access::file
class:
content
Data type: Optional[String]
The content of the file resource.
Default value: undef
source
Data type: Optional[String]
The source of the file resource.
Default value: undef
sendmail::aliases
The class manages the file either as a single file resource or each entry
in the file separately. The file is managed as a whole using the source
or content
parameters. The entries
parameter is used to manage each
entry separately. Preferable this is done with hiera using automatic
parameter lookup.
Examples
Set up aliases using a configuration from hiera
class { 'sendmail::aliases': }
Set up aliases using the given file
class { 'sendmail::aliases':
source => 'puppet:///modules/sendmail/aliases',
}
Parameters
The following parameters are available in the sendmail::aliases
class:
content
Data type: Optional[String]
The desired contents of the aliases file. This allows
managing the aliases file as a whole. Changes to the file automatically
triggers a rebuild of the aliases database file. This attribute is
mutually exclusive with source
and entries
.
Default value: undef
source
Data type: Optional[String]
A source file for the aliases file. This allows managing the
aliases file as a whole. Changes to the file automatically triggers
a rebuild of the aliases database file. This attribute is mutually
exclusive with content
and entries
.
Default value: undef
entries
Data type: Hash[String,Data]
A hash that will be used to create sendmail::aliases::entry
resources. This attribute is mutually exclusive with content
and
source
. The class can be used to create aliases defined in hiera.
The hiera hash should look like this:
sendmail::aliases::entries:
'fred':
recipient: 'barney@example.org'
Default value: {}
sendmail::aliases::file
Create the Sendmail aliases file.
Examples
class { 'sendmail::aliases::file': }
Parameters
The following parameters are available in the sendmail::aliases::file
class:
content
Data type: Optional[String]
The content of the file resource.
Default value: undef
source
Data type: Optional[String]
The source of the file resource.
Default value: undef
sendmail::authinfo
Manage the Sendmail authinfo db file.
Examples
class { 'sendmail::authinfo': }
class { 'sendmail::authinfo':
source => 'puppet:///modules/sendmail/authinfo',
}
Parameters
The following parameters are available in the sendmail::authinfo
class:
content
Data type: Optional[String]
The desired contents of the authinfo file. This allows
managing the authinfo file as a whole. Changes to the file automatically
triggers a rebuild of the authinfo database file. This attribute is
mutually exclusive with source
.
Default value: undef
source
Data type: Optional[String]
A source file for the authinfo file. This allows managing
the authinfo file as a whole. Changes to the file automatically triggers
a rebuild of the authinfo database file. This attribute is mutually
exclusive with content
.
Default value: undef
entries
Data type: Hash[String,Data]
A hash that will be used to create sendmail::authinfo::entry resources. This class can be used to create authinfo entries defined in hiera. The hiera hash should look like this:
sendmail::authinfo::entries:
'AuthInfo:example.com':
value: '"U=auth" "P=secret"'
'AuthInfo:192.168.67.89':
value: '"U=fred" "P=wilma"'
Default value: {}
sendmail::authinfo::file
Create the Sendmail authinfo db file.
Examples
class { 'sendmail::authinfo::file': }
Parameters
The following parameters are available in the sendmail::authinfo::file
class:
content
Data type: Optional[String]
The content of the file resource.
Default value: undef
source
Data type: Optional[String]
The source of the file resource.
Default value: undef
sendmail::domaintable
The class manages the file either as a single file resource or each entry
in the file separately. The file is managed as a whole using the source
or content
parameters. The entries
parameter is used to manage each
entry separately. Preferable this is done with hiera using automatic
parameter lookup.
Examples
Manage the domaintable using hiera
class { 'sendmail::domaintable': }
Manage the domaintable using the given file
class { 'sendmail::domaintable':
source => 'puppet:///modules/sendmail/domaintable',
}
Parameters
The following parameters are available in the sendmail::domaintable
class:
content
Data type: Optional[String]
The desired contents of the domaintable file. This allows
managing the domaintable file as a whole. Changes to the file
automatically triggers a rebuild of the domaintable database file. This
attribute is mutually exclusive with source
and entries
.
Default value: undef
source
Data type: Optional[String]
A source file for the domaintable file. This allows managing
the domaintable file as a whole. Changes to the file automatically
triggers a rebuild of the domaintable database file. This attribute is
mutually exclusive with content
and entries
.
Default value: undef
entries
Data type: Hash[String,Data]
A hash that will be used to create
sendmail::domaintable::entry
resources. This class can be used to
create domaintable entries defined in hiera. The hiera hash should look
like this:
sendmail::domaintable::entries:
'example.com':
value: 'example.org'
'example.net':
value: 'example.org'
Default value: {}
sendmail::domaintable::file
Manage the Sendmail domaintable db file.
Examples
class { 'sendmail::domaintable::file': }
Parameters
The following parameters are available in the sendmail::domaintable::file
class:
content
Data type: Optional[String]
The content of the file resource.
Default value: undef
source
Data type: Optional[String]
The source of the file resource.
Default value: undef
sendmail::genericstable
The class manages the file either as a single file resource or each entry
in the file separately. The file is managed as a whole using the source
or content
parameters. The entries
parameter is used to manage each
entry separately. Preferable this is done with hiera using automatic
parameter lookup.
Use the sendmail::mc::generics_domain
type to configure the domains for
which non-local user addresses should be rewritten.
Examples
Manage the generictable using hiera
class { 'sendmail::genericstable': }
Manage the generictable using the provided file
class { 'sendmail::genericstable':
source => 'puppet:///modules/sendmail/genericstable',
}
Parameters
The following parameters are available in the sendmail::genericstable
class:
content
Data type: Optional[String]
The desired contents of the genericstable file. This allows
managing the genericstable file as a whole. Changes to the file
automatically triggers a rebuild of the genericstable database file.
This attribute is mutually exclusive with source
and entries
.
Default value: undef
source
Data type: Optional[String]
A source file for the genericstable file. This allows
managing the genericstable file as a whole. Changes to the file
automatically triggers a rebuild of the genericstable database file.
This attribute is mutually exclusive with content
and entries
.
Default value: undef
entries
Data type: Hash[String,Data]
A hash that will be used to create
sendmail::genericstable::entry
resources. This class can be used to
create genericstable entries defined in hiera. The hiera hash should
look like this:
sendmail::genericstable::entries:
'fred@example.com':
value: 'fred@example.org'
'barney':
value: 'barney@example.org'
Default value: {}
sendmail::genericstable::file
Manage the Sendmail genericstable db file.
Examples
class { 'sendmail::genericstable::file': }
Parameters
The following parameters are available in the sendmail::genericstable::file
class:
content
Data type: Optional[String]
The content of the file resource.
Default value: undef
source
Data type: Optional[String]
The source of the file resource.
Default value: undef
sendmail::mailertable
The class manages the file either as a single file resource or each entry
in the file separately. The file is managed as a whole using the source
or content
parameters. The entries
parameter is used to manage each
entry separately. Preferable this is done with hiera using automatic
parameter lookup.
Examples
Manage the mailertable using hiera
class { 'sendmail::mailertable': }
Manage the mailertable using the provided file
class { 'sendmail::mailertable':
source => 'puppet:///modules/sendmail/mailertable',
}
Parameters
The following parameters are available in the sendmail::mailertable
class:
content
Data type: Optional[String]
The desired contents of the mailertable file. This allows
managing the mailertable file as a whole. Changes to the file
automatically triggers a rebuild of the mailertable database file. This
attribute is mutually exclusive with source
and entries
.
Default value: undef
source
Data type: Optional[String]
A source file for the mailertable file. This allows managing
the mailertable file as a whole. Changes to the file automatically
triggers a rebuild of the mailertable database file. This attribute is
mutually exclusive with content
and entries
.
Default value: undef
entries
Data type: Hash[String,Data]
A hash that will be used to create
sendmail::mailertable::entry
resources. This class can be used to
create mailertable entries defined in hiera. The hiera hash should look
like this:
sendmail::mailertable::entries:
'.example.com':
value: 'smtp:relay.example.com'
'www.example.org':
value: 'relay:relay.example.com'
'.example.net':
value: 'error:5.7.0:550 mail is not accepted'
Default value: {}
sendmail::mailertable::file
Manage the Sendmail mailertable db file.
Examples
class { 'sendmail::mailertable::file': }
Parameters
The following parameters are available in the sendmail::mailertable::file
class:
content
Data type: Optional[String]
The content of the file resource.
Default value: undef
source
Data type: Optional[String]
The source of the file resource.
Default value: undef
sendmail::makeall
Rebuild all config files for the Sendmail MTA using a Makefile
sendmail::mc::privacy_flags
Each option is enabled by setting the associated boolean parameter to
true
. See the Sendmail documentation for the meaning of the flags.
Examples
Enable two specific privacy flags
class { 'sendmail::mc::privacy_flags':
goaway => true,
noetrn => true,
}
Parameters
The following parameters are available in the sendmail::mc::privacy_flags
class:
authwarnings
goaway
needexpnhelo
needmailhelo
needvrfyhelo
noactualrecipient
nobodyreturn
noetrn
noexpn
noreceipts
noverb
novrfy
public
restrictexpand
restrictmailq
restrictqrun
authwarnings
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
goaway
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
needexpnhelo
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
needmailhelo
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
needvrfyhelo
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
noactualrecipient
Data type: Boolean
Whether the privacy option of the same name should
be enabled. Valid options: true
or false
.
Default value: false
nobodyreturn
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
noetrn
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
noexpn
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
noreceipts
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
noverb
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
novrfy
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
public
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
restrictexpand
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
restrictmailq
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
restrictqrun
Data type: Boolean
Whether the privacy option of the same name should be
enabled. Valid options: true
or false
.
Default value: false
sendmail::mc::timeouts
This class allows setting various timeouts for Sendmail without having to
use the sendmail::mc::define
macro individually for each entry.
Examples
Disable RFC1413 ident requests
class { 'sendmail::mc::timeouts':
ident => '0',
}
Parameters
The following parameters are available in the sendmail::mc::timeouts
class:
aconnect
auth
command
connect
control
datablock
datafinal
datainit
fileopen
helo
hoststatus
iconnect
ident
initial
lhlo
mail
misc
quit
rcpt
rset
starttls
aconnect
Data type: Optional[String]
Timeout for all connection attempts when trying to reach one or multiple hosts for sending a single mail.
Default value: undef
auth
Data type: Optional[String]
Timeout when waiting for AUTH negotiation.
Default value: undef
command
Data type: Optional[String]
Timeout when waiting for the next SMTP command.
Default value: undef
connect
Data type: Optional[String]
Timeout for one connection attempt when trying to establish
a network connection. Also see then iconnect
parameter.
Default value: undef
control
Data type: Optional[String]
Timout when waiting for a command on the control socket.
Default value: undef
datablock
Data type: Optional[String]
Timeout when waiting on a read operation during the DATA phase.
Default value: undef
datafinal
Data type: Optional[String]
Timeout when waiting for the acknowledgment after sending the final dot in the DATA phase.
Default value: undef
datainit
Data type: Optional[String]
Timeout when waiting for the acknowledgment of the DATA command.
Default value: undef
fileopen
Data type: Optional[String]
Timeout when waiting for access to a local file.
Default value: undef
helo
Data type: Optional[String]
Timeout when waiting for the acknowledgment of the HELO or EHLO commands.
Default value: undef
hoststatus
Data type: Optional[String]
Timeout for invalidation of hoststatus information during a single queue run.
Default value: undef
iconnect
Data type: Optional[String]
Timeout for the first connection attempt to a host when
trying to establish a network connection. Also see then connect
parameter.
Default value: undef
ident
Data type: Optional[String]
Timeout when waiting to a response to a RFC1413 identification
protocol query. Set this to 0
to disable the identification protocol.
Default value: undef
initial
Data type: Optional[String]
Timeout when waiting for the initial greeting message.
Default value: undef
lhlo
Data type: Optional[String]
Timeout when waiting for the reply to the initial LHLO command on an LMTP connection.
Default value: undef
mail
Data type: Optional[String]
Timeout when waiting for the acknowledgment of the MAIL command.
Default value: undef
misc
Data type: Optional[String]
Timeout when waiting for the acknowledgment of various other commands (VERB, NOOP, ...).
Default value: undef
quit
Data type: Optional[String]
Timeout when waiting for the acknowledgment of the QUIT command.
Default value: undef
rcpt
Data type: Optional[String]
Timeout when waiting for the acknowledgment of the RCPT command.
Default value: undef
rset
Data type: Optional[String]
Timeout when waiting for the acknowledgment of the RSET command.
Default value: undef
starttls
Data type: Optional[String]
Timeout when waiting for STARTTLS negotiation.
Default value: undef
sendmail::mc::trust_auth_mech
Add the TRUST_AUTH_MECH
macro to the sendmail.mc file.
Examples
Activate PLAIN
authentication
class { 'sendmail::mc::trust_auth_mech':
trust_auth_mech => 'PLAIN',
}
Activate PLAIN
and DIGEST-MD5
authentication
class { 'sendmail::mc::trust_auth_mech':
trust_auth_mech => [ 'PLAIN', 'DIGEST-MD5', ],
}
Parameters
The following parameters are available in the sendmail::mc::trust_auth_mech
class:
trust_auth_mech
Data type: Variant[String,Array[String]]
The value of the TRUST_AUTH_MECH
macro to set. If
this is a string it is used as-is. For an array the value will be
concatenated into a string.
sendmail::nullclient
No mail can be received from the outside since the Sendmail daemon only
listens on the localhost address 127.0.0.1
. All local mail is forwarded
to a given mail hub.
This is a convenience class to make the configuration simple. Internally it
declares the sendmail
class using appropriate parameters. Normally no
other configuration should be necessary.
Examples
Create a nullclient config forwarding to a given hub
class { 'sendmail::nullclient':
mail_hub => '[192.168.1.1]',
}
Parameters
The following parameters are available in the sendmail::nullclient
class:
mail_hub
port
port_option_modify
enable_ipv4_msa
enable_ipv6_msa
enable_msp_trusted_users
trusted_users
domain_name
max_message_size
log_level
ca_cert_file
ca_cert_path
server_cert_file
server_key_file
client_cert_file
client_key_file
crl_file
dh_params
tls_srv_options
cipher_list
server_ssl_options
client_ssl_options
mail_hub
Data type: String
The hostname or IP address of the mail hub where all mail is forwarded to. It can be enclosed in brackets to prevent MX lookups.
port
Data type: Pattern[/^[0-9]+$/]
The port used for the local message submission agent.
Default value: '587'
port_option_modify
Data type: Optional[Pattern[/^[abcfhruACEOS]*$/]]
Port option modifiers for the local message
submission agent. The parameter is used to set the
daemon_port_options
. A useful value for the nullclient configuration
might be S
to prevent offering STARTTLS on the MSA port.
Default value: undef
enable_ipv4_msa
Data type: Boolean
Enable the local message submission agent on the
IPv4 loopback address (127.0.0.1
). Valid options: true
or false
.
Default value: true
enable_ipv6_msa
Data type: Boolean
Enable the local message submission agent on the
IPv6 loopback address (::1
). Valid options: true
or false
.
Default value: true
enable_msp_trusted_users
Data type: Boolean
Whether the trusted users file feature is
enabled for the message submission program. This may be necessary if you
want to allow certain users to change the sender address using sendmail -f
. Valid options: true
or false
.
Default value: false
trusted_users
Data type: Array[String]
An array of user names that will be written into the trusted users file. Leading or trailing whitespace is ignored. Empty entries are also ignored.
Default value: []
domain_name
Data type: Optional[String]
Sets the official canonical name of the local machine.
Normally this parameter is not required as Sendmail uses the fully
qualified domain name by default. Setting this parameter will override
the value of the $j
macro in the sendmail.cf file.
Default value: undef
max_message_size
Data type: Optional[Sendmail::Messagesize]
Define the maximum message size that will be
accepted. This can be a pure numerical value given in bytes
(e.g. 33554432) or a number with a prefixed byte unit (e.g. 32MB). The
conversion is done using the 1024 convention (see the to_bytes
function
in the stdlib
module), so valid prefixes are either k
for 1024 bytes
or M
for 1048576 bytes.
Default value: undef
log_level
Data type: Optional[Sendmail::Loglevel]
The loglevel for the sendmail process. Valid options: a numeric value.
Default value: undef
ca_cert_file
Data type: Optional[Stdlib::Absolutepath]
The filename of the SSL CA certificate.
Default value: undef
ca_cert_path
Data type: Optional[Stdlib::Absolutepath]
The directory where SSL CA certificates are kept.
Default value: undef
server_cert_file
Data type: Optional[Stdlib::Absolutepath]
The filename of the SSL server certificate for inbound connections.
Default value: undef
server_key_file
Data type: Optional[Stdlib::Absolutepath]
The filename of the SSL server key for inbound connections.
Default value: undef
client_cert_file
Data type: Optional[Stdlib::Absolutepath]
The filename of the SSL client certificate for outbound connections.
Default value: undef
client_key_file
Data type: Optional[Stdlib::Absolutepath]
The filename of the SSL client key for outbound connections.
Default value: undef
crl_file
Data type: Optional[Stdlib::Absolutepath]
The filename with a list of revoked certificates.
Default value: undef
dh_params
Data type: Optional[Sendmail::DHParam]
The DH parameters used for encryption. This can be one of
the numbers 512
, 1024
, 2048
or a filename with generated
parameters.
Default value: undef
tls_srv_options
Data type: Optional[Enum['V']]
The parameter adjusts the server TLS settings. This
can currently be either the letter V
or the empty string. Setting this
parameter to V
disables the request for a client certificate.
Default value: undef
cipher_list
Data type: Optional[String]
Set the available ciphers for encrypted connections.
Default value: undef
server_ssl_options
Data type: Optional[String]
Configure the SSL connection flags for inbound connections.
Default value: undef
client_ssl_options
Data type: Optional[String]
Configure the SSL connection flags for outbound connections.
Default value: undef
sendmail::userdb
The class manages the file either as a single file resource or each entry
in the file separately. The file is managed as a whole using the source
or content
parameters. The entries
parameter is used to manage each
entry separately. Preferable this is done with hiera using automatic
parameter lookup.
Examples
Manage the userdb using hiera
class { 'sendmail::userdb': }
Manage the userdb using the provided file
class { 'sendmail::userdb':
source => 'puppet:///modules/sendmail/userdb',
}
Parameters
The following parameters are available in the sendmail::userdb
class:
content
Data type: Optional[String]
The desired contents of the userdb file. This allows
managing the userdb file as a whole. Changes to the file automatically
triggers a rebuild of the userdb database file. This attribute is
mutually exclusive with source
and entries
.
Default value: undef
source
Data type: Optional[String]
A source file for the userdb file. This allows managing the
userdb file as a whole. Changes to the file automatically triggers
a rebuild of the userdb database file. This attribute is mutually
exclusive with content
and entries
.
Default value: undef
entries
Data type: Hash[String,Data]
A hash that will be used to create sendmail::userdb::entry
resources. This class can be used to create userdb entries defined in
hiera. The hiera hash should look like this:
sendmail::userdb::entries:
'fred:maildrop':
value: 'fred@example.org'
'barney:maildrop':
value: 'barney@example.org'
Default value: {}
sendmail::userdb::file
Manage the Sendmail userdb file.
Examples
class { 'sendmail::userdb::file': }
Parameters
The following parameters are available in the sendmail::userdb::file
class:
content
Data type: Optional[String]
The content of the file resource.
Default value: undef
source
Data type: Optional[String]
The source of the file resource.
Default value: undef
sendmail::virtusertable
The class manages the file either as a single file resource or each entry
in the file separately. The file is managed as a whole using the source
or content
parameters. The entries
parameter is used to manage each
entry separately. Preferable this is done with hiera using automatic
parameter lookup.
Examples
Manage the virtusertable using hiera
class { 'sendmail::virtusertable': }
Manage the virtusertable using the provided file
class { 'sendmail::virtusertable':
source => 'puppet:///modules/sendmail/virtusertable',
}
Parameters
The following parameters are available in the sendmail::virtusertable
class:
content
Data type: Optional[String]
The desired contents of the virtusertable file. This allows
managing the virtusertable file as a whole. Changes to the file
automatically triggers a rebuild of the virtusertable database file.
This attribute is mutually exclusive with source
and entries
.
Default value: undef
source
Data type: Optional[String]
A source file for the virtusertable file. This allows
managing the virtusertable file as a whole. Changes to the file
automatically triggers a rebuild of the virtusertable database file.
This attribute is mutually exclusive with content
and entries
.
Default value: undef
entries
Data type: Hash[String,Data]
A hash that will be used to create
sendmail::virtusertable::entry
resources. This class can be used to
create virtusertable entries defined in hiera. The hiera hash should
look like this:
sendmail::virtusertable::entries:
'info@example.com':
value: 'fred'
'@example.org':
value: 'barney'
Default value: {}
sendmail::virtusertable::file
Manage the Sendmail virtusertable db file.
Examples
class { 'sendmail::virtusertable::file': }
Parameters
The following parameters are available in the sendmail::virtusertable::file
class:
content
Data type: Optional[String]
The content of the file resource.
Default value: undef
source
Data type: Optional[String]
The source of the file resource.
Default value: undef
Defined types
sendmail::access::entry
The feature access_db
must also be enabled by calling
sendmail::mc::feature
to make Sendmail use the access db file.
Examples
Create an access entry for a domain
sendmail::access::entry { 'example.com':
value => 'RELAY',
}
Parameters
The following parameters are available in the sendmail::access::entry
defined type:
ensure
Data type: Enum['present','absent']
Used to create or remove the access db entry. Valid options:
present
, absent
.
Default value: 'present'
key
Data type: String
The key used by Sendmail for the lookup. This could for example be a domain name.
Default value: $name
value
Data type: Optional[String]
The value for the given key. For the access map this is
typically something like OK
, REJECT
or DISCARD
.
Default value: undef
sendmail::aliases::entry
Manage an entry in the Sendmail alias file.
Examples
Add a local alias for fred
sendmail::aliases::entry { 'fred':
recipient => 'barney@example.org',
}
Parameters
The following parameters are available in the sendmail::aliases::entry
defined type:
alias_name
Data type: String
The name of the alias to create.
Default value: $name
ensure
Data type: Enum['present','absent']
Used to create or remove the alias entry. Valid options:
present
, absent
.
Default value: 'present'
recipient
Data type: Optional[Variant[String,Array[String]]]
The recipient where the mail is redirected to. This can be a string for one recipient or an array of strings for multiple recipients.
Default value: undef
sendmail::authinfo::entry
Manage an entry in the Sendmail authinfo db file.
Examples
Add an authinfo entry
sendmail::authinfo::entry { 'example.com':
password => 'secret',
authorization_id => 'auth',
}
Parameters
The following parameters are available in the sendmail::authinfo::entry
defined type:
ensure
Data type: Enum['present','absent']
Used to create or remove the authinfo db entry.
Default value: 'present'
mechanisms
Data type: Array[String]
The list of preferred authentication mechanisms.
Default value: []
address
Data type: String
The key used by Sendmail for the database lookup. This can
be an IPv4 address (e.g. 192.168.67.89
), an IPv6 address (e.g.
IPv6:2001:DB18::23f4
), a hostname (e.g. www.example.org
) or a domain
name (e.g. example.com
). The database key is required to start with
the literal expression AuthInfo:
. This prefix will be added
automatically if necessary.
Default value: $name
password
Data type: Optional[String]
The password used for remote authentication in clear text.
Exactly one of password
or password_base64
must be set.
Default value: undef
password_base64
Data type: Optional[String]
The password used for remote authentication in
Base64 encoding. Exactly one of password
or password_base64
must be
set.
Default value: undef
authorization_id
Data type: Optional[String]
The user (authorization) identifier. One of the
parameters authorization_id
or authentication_id
or both must be set.
Default value: undef
authentication_id
Data type: Optional[String]
The authentication identifier. One of the
parameters authorization_id
or authentication_id
or both must be set.
Default value: undef
realm
Data type: Optional[String]
The administrative realm to use.
Default value: undef
sendmail::domaintable::entry
Manage an entry in the Sendmail domaintable file.
Examples
Add an entry to the domaintable
sendmail::domaintable::entry { 'example.com':
value => 'example.org',
}
Parameters
The following parameters are available in the sendmail::domaintable::entry
defined type:
ensure
Data type: Enum['present','absent']
Used to create or remove the domaintable db entry. Valid
options: present
, absent
.
Default value: 'present'
key
Data type: String
The key used by Sendmail for the lookup. This should normally be a domain name.
Default value: $name
value
Data type: Optional[String]
The value for the given key. For the domaintable map this is typically another domain name.
Default value: undef
sendmail::genericstable::entry
Manage an entry in the Sendmail genericstable file.
Examples
Override the recipient fred@example.com
with another address
sendmail::genericstable::entry { 'fred@example.com':
value => 'fred@example.org',
}
Forward local mail to barney
to a remote address
sendmail::genericstable::entry { 'barney':
value => 'barney@example.org',
}
Parameters
The following parameters are available in the sendmail::genericstable::entry
defined type:
ensure
Data type: Enum['present','absent']
Used to create or remove the genericstable db entry. Valid
options: present
, absent
.
Default value: 'present'
key
Data type: String
The key used by Sendmail for the lookup. This is normally a username or a user and domain name.
Default value: $name
value
Data type: Optional[String]
The value for the given key. For the genericstable map this
is typically something like user@example.org
.
Default value: undef
sendmail::mailertable::entry
Manage an entry in the Sendmail mailertable file.
Examples
Forward all mail for the example.com
domain to a given relay
sendmail::mailertable::entry { '.example.com':
value => 'smtp:relay.example.com',
}
Reject all mail for the example.net
domain with a given error
sendmail::mailertable::entry { '.example.net':
value => 'error:5.7.0:550 mail is not accepted',
}
Parameters
The following parameters are available in the sendmail::mailertable::entry
defined type:
ensure
Data type: Enum['present','absent']
Used to create or remove the mailertable db entry. Valid
options: present
, absent
.
Default value: 'present'
key
Data type: String
The key used by Sendmail for the lookup. This should either be a fully qualified host name or a domain name with a leading dot.
Default value: $name
value
Data type: Optional[String]
The value for the given key. For the mailertable map this is
typically something like smtp:hostname
. The error mailer can be used
to configure specific errors for certain hosts.
Default value: undef
sendmail::mc::daemon_options
Add the DAEMON_OPTIONS
macro to the sendmail.mc file.
Examples
Define a MTA daemon for port 25 using IPv4
sendmail::mc::daemon_options { 'MTA-v4':
daemon_name => 'MTA',
family => 'inet',
port => '25',
}
Parameters
The following parameters are available in the sendmail::mc::daemon_options
defined type:
daemon_name
family
addr
port
children
delivery_mode
input_filter
listen
modify
delay_la
queue_la
refuse_la
send_buf_size
receive_buf_size
daemon_name
Data type: String
The name of the daemon to use. The logfile will contain this name to identify the daemon.
Default value: $name
family
Data type: Optional[Enum['inet', 'inet6', 'iso']]
The network family type. Valid options: inet
, inet6
or
iso
.
Default value: undef
addr
Data type: Optional[String]
The network address to listen on for remote connections. This can be a hostname or network address.
Default value: undef
port
Data type: Optional[String]
The port used by the daemon. This can be either a numeric port
number or a service name like smtp
for port 25 or submission
for port
587.
Default value: undef
children
Data type: Optional[String]
The maximum number of processes to fork for this daemon.
Default value: undef
delivery_mode
Data type: Optional[Sendmail::Deliverymode]
The mode of delivery for this daemon. Valid options:
background
, deferred
, interactive
or queueonly
.
Default value: undef
input_filter
Data type: Optional[Variant[String,Array[String]]]
A list of milters to use. This can either be an array of milter names or a single string, where the milter names are separated by colons.
Default value: undef
listen
Data type: Optional[String]
The length of the listen queue used by the operating system.
Default value: undef
modify
Data type: Optional[String]
Single letter flags to modify the daemon behaviour. See the Sendmail documention for details.
Default value: undef
delay_la
Data type: Optional[String]
The local load average at which connections are delayed before they are accepted.
Default value: undef
queue_la
Data type: Optional[String]
The local load average at which received mail is queued and not delivered immediately.
Default value: undef
refuse_la
Data type: Optional[String]
The local load average at which mail is no longer accepted.
Default value: undef
send_buf_size
Data type: Optional[String]
The size of the network send buffer used by the operating system. The value is a size in bytes.
Default value: undef
receive_buf_size
Data type: Optional[String]
The size of the network receive buffer used by the operating system. The value is a size in bytes.
Default value: undef
sendmail::mc::define
Add m4 macro defines to the sendmail.mc file.
Examples
Set a configuration item using m4 quotes
sendmail::mc::define { 'confFOO':
expansion => 'foo',
}
Set a configuration item without m4 quotes
sendmail::mc::define { 'confBAR':
expansion => 'foo',
use_quotes => false,
}
Parameters
The following parameters are available in the sendmail::mc::define
defined type:
expansion
Data type: Optional[Variant[String,Integer]]
The expansion defined for the macro.
Default value: undef
use_quotes
Data type: Boolean
A boolean that indicates if the expansion should be
quoted (using m4 quotes). Valid options: true
or false
.
Default value: true
macro_name
Data type: String
The name of the macro that will be defined. This will be the first argument of the m4 define builtin. Note: The macro name should not be quoted as it will always be quoted in the template.
Default value: $name
sendmail::mc::domain
Add the DOMAIN
macro to the sendmail.mc file.
Examples
Include settings for the generic
domain
sendmail::mc::domain { 'generic': }
Parameters
The following parameters are available in the sendmail::mc::domain
defined type:
domain_name
Data type: String
The name of the sendmail domain file as a string. The
value is used as argument to the DOMAIN
macro in the generated
sendmail.mc file. This will include the m4 file with domain specific
settings.
Default value: $title
sendmail::mc::enhdnsbl
Manage enhanced DNS blacklist entries
Examples
Include the DNS blacklist dialups.mail-abuse.org
sendmail::mc::enhdnsbl { 'dialups.mail-abuse.org':
reject_message => '"550 dial-up site refused"',
allow_temporary_failure => true,
lookup_result => '127.0.0.3.',
}
Parameters
The following parameters are available in the sendmail::mc::enhdnsbl
defined type:
blacklist
Data type: String
The DNS name to query the blacklist.
Default value: $name
allow_temporary_failure
Data type: Boolean
Determine what happens when a temporary
failure of the DNS lookup occurs. The message is accepted when this
parameter is set to false
. A temporary error is signaled when this is
set to true
.
Default value: false
reject_message
Data type: Optional[String]
The error message used when rejecting a message.
Default value: undef
lookup_result
Data type: Optional[String]
Check the DNS lookup for this result. Leave this parameter unset to block the message as long as anything is returned from the lookup.
Default value: undef
sendmail::mc::feature
Add the FEATURE
macro to the sendmail.mc file.
Examples
Enable the mailertable
feature
sendmail::mc::feature { 'mailertable': }
Enable the mailertable
feature using the given file location
sendmail::mc::feature { 'mailertable':
args => [ 'hash /etc/mail/mailertable' ],
}
Parameters
The following parameters are available in the sendmail::mc::feature
defined type:
feature_name
Data type: String
The name of the feature that will be used. This will
be the first argument of the FEATURE()
. Note: The feature name
should not be quoted as it will always be quoted in the template.
Default value: $name
args
Data type: Variant[String,Array[String]]
The arguments used for the feature. This can be a string (one
argument) or and an array and it will be used for the following arguments
of the FEATURE()
.
Default value: []
use_quotes
Data type: Boolean
A boolean that indicates if the arguments should be
quoted (using m4 quotes). Valid options: true
or false
.
Default value: true
sendmail::mc::generics_domain
Add the GENERICS_DOMAIN
macro to the sendmail.mc file.
Examples
Enable genericstable processing for the domain example.net
sendmail::mc::generics_domain { 'example.net': }
Parameters
The following parameters are available in the sendmail::mc::generics_domain
defined type:
domain_name
Data type: String
The name of the domain for which the genericstable is enabled.
Default value: $name
sendmail::mc::include
Add include fragments to the sendmail.mc file.
Examples
Include a milter setup file to the configuration
sendmail::mc::include { '/etc/mail/m4/clamav-milter.m4': }
Parameters
The following parameters are available in the sendmail::mc::include
defined type:
filename
Data type: Stdlib::Absolutepath
The absolute path of the file to include.
Default value: $name
order
Data type: String
The position in the sendmail.mc file where the include
statement will appear. This requires internal knowledge of the sendmail
module. See the Puppet class sendmail::mc
for details. The default
generates the include statements just before the MAILER
section.
Default value: '59'
sendmail::mc::ldaproute_domain
Add the LDAPROUTE_DOMAIN
macro to the sendmail.mc file.
Examples
Enable LDAP routing for example.net
sendmail::mc::ldaproute_domain { 'example.net': }
Parameters
The following parameters are available in the sendmail::mc::ldaproute_domain
defined type:
domain_name
Data type: String
The name of the domain for which LDAP routing is enabled.
Default value: $name
sendmail::mc::local_config
Add a LOCAL_CONFIG
section into the sendmail.mc file.
Examples
Add the X-AuthUser header to each mail
sendmail::mc::local_config { 'X-AuthUser':
content => 'HX-AuthUser: ${auth_authen}',
}
Parameters
The following parameters are available in the sendmail::mc::local_config
defined type:
content
Data type: Optional[String]
The desired contents of the local config section. This
attribute is mutually exclusive with source
.
Default value: undef
source
Data type: Optional[String]
A source file included as the local config section. This
attribute is mutually exclusive with content
.
Default value: undef
sendmail::mc::mailer
Add a MAILER
macro to the sendmail.mc file.
Examples
Add the local mailer to the configuration
sendmail::mc::mailer { 'local': }
Add the SMTP mailer to the configuration
sendmail::mc::mailer { 'smtp': }
Parameters
The following parameters are available in the sendmail::mc::mailer
defined type:
mailer
Data type: String
The name of the mailer to add to the configuration. The position of the mailer in the configuration file is determined according to the Bat Book.
Default value: $name
sendmail::mc::masquerade_as
Add the MASQUERADE_AS
macro to the sendmail.mc file.
Examples
Masquerade as example.com
including envelope adresses
sendmail::mc::masquerade_as { 'example.com':
masquerade_envelope => true,
}
Parameters
The following parameters are available in the sendmail::mc::masquerade_as
defined type:
masquerade_as
masquerade_domain
masquerade_domain_file
masquerade_exception
masquerade_exception_file
masquerade_envelope
allmasquerade
limited_masquerade
local_no_masquerade
masquerade_entire_domain
exposed_user
exposed_user_file
masquerade_as
Data type: String
Mail being sent is rewritten as coming from the indicated address.
Default value: $name
masquerade_domain
Data type: Array[String]
Normally masquerading only rewrites mail from the local host. This parameter sets a set of domain or host names that is used for masquerading.
Default value: []
masquerade_domain_file
Data type: Optional[Stdlib::Absolutepath]
The set of domain or host names to be used for masquerading can also be read from the file given here.
Default value: undef
masquerade_exception
Data type: Array[String]
This parameter can set exceptions if not all hosts or subdomains for a given domain should be rewritten.
Default value: []
masquerade_exception_file
Data type: Optional[Stdlib::Absolutepath]
The exceptions can also be read from the file given here.
Default value: undef
masquerade_envelope
Data type: Boolean
Normally only header addresses are used for
masquerading. By setting this parameter to true
, also envelope
addresses are rewritten.
Default value: false
allmasquerade
Data type: Boolean
Enable the allmasquerade
feature if set to
true
.
Default value: false
limited_masquerade
Data type: Boolean
Enable the limited_masquerade
feature if set to
true
.
Default value: false
local_no_masquerade
Data type: Boolean
Enable the local_no_masquerade
feature if set
to true
.
Default value: false
masquerade_entire_domain
Data type: Boolean
Enable the masquerade_entire_domain
feature if set to true
.
Default value: false
exposed_user
Data type: Array[String]
An array of usernames that should not be masqueraded.
This may be useful for system users (root
has been exposed by default
prior to Sendmail 8.10).
Default value: []
exposed_user_file
Data type: Optional[Stdlib::Absolutepath]
The usernames that should not be masqueraded can also be read from the file given here.
Default value: undef
sendmail::mc::milter
Manage Sendmail Milter configuration in sendmail.mc
Examples
Add the greylist
milter using a local socket
sendmail::mc::milter { 'greylist':
socket_type => 'local',
socket_spec => '/var/run/milter-greylist/milter-greylist.sock',
}
Add the greylist
milter using a TCP/IP socket
sendmail::mc::milter { 'greylist':
socket_type => 'inet',
socket_spec => '12345@192.168.0.42',
}
Parameters
The following parameters are available in the sendmail::mc::milter
defined type:
socket_type
socket_spec
flags
send_timeout
receive_timeout
eom_timeout
connect_timeout
order
milter_name
enable
socket_type
Data type: Enum['local','unix','inet','inet6']
The type of socket to use for connecting to the milter.
Valid values: local
, unix
, inet
, inet6
socket_spec
Data type: String
The socket specification for connecting to the milter.
For the type local
(unix
is a synonym) this is the full path to the
Unix-domain socket. For the inet
and inet6
type socket this must be
the port number, a literal @
character and the host or address
specification.
flags
Data type: Enum['R','T','4','']
Either the empty string or a single character to specify how
milter failures are handled by Sendmail. The letter R
rejects the
message, a T
causes a temporary failure and the character 4
(available with Sendmail V8.4 or later) rejects with a 421 response code.
If the empty string is used, Sendmail will treat a milter failure as if
the milter wasn't configured.
Default value: 'T'
send_timeout
Data type: Optional[Sendmail::Timeout]
Timeout when sending data from the MTA to the Milter. The default is undefined (using the Sendmail default 10sec).
Default value: undef
receive_timeout
Data type: Optional[Sendmail::Timeout]
Timeout when reading a reply from the Milter. The default is undefined (using the Sendmail default 10sec).
Default value: undef
eom_timeout
Data type: Optional[Sendmail::Timeout]
Overall timeout from sending the messag to Milter until the final end of message reply is received. The default is undefined (using the Sendmail default 5min).
Default value: undef
connect_timeout
Data type: Optional[Sendmail::Timeout]
Connection timeout. The default value is undefined (using the Sendmail default 5min).
Default value: undef
order
Data type: String
A string used to determine the order of the mail filters in the configuration file. This also defines the order in which the filters are called.
Default value: '00'
milter_name
Data type: String
The name of the milter to create.
Default value: $name
enable
Data type: Boolean
A boolean to indicate if the milter should automatically be
enabled. If this is true
(the default) then the milter will be called
by Sendmail for every incoming mail. If this is set to false
then the
milter is only defined. It needs to be enabled by either setting the
parameter input_filter
for sendmail::mc::daemon_options
or defining
confINPUT_MAIL_FILTERS
. Internally this parameter determines if the
INPUT_MAIL_FILTER()
or MAIL_FILTER()
macros are used.
Default value: true
sendmail::mc::modify_mailer_flags
Add a MODIFY_MAILER_FLAGS
macro to the sendmail.mc file.
Examples
Add the O
flag to the SMTP
mailer
sendmail::mc::modify_mailer_flags { 'SMTP':
flags => '+O',
}
Parameters
The following parameters are available in the sendmail::mc::modify_mailer_flags
defined type:
mailer_name
Data type: String
The name of the mailer for which the flags will be
changed. This name is case-sensitive and must conform to the name of the
mailer. Usually this will be a name in uppercase (e.g. SMTP
or
LOCAL
).
Default value: $name
flags
Data type: String
The flags to change. Adding single flags is possible by
prefixing the flag with a +
symbol. Removing single flags from the
mailer can be done with a -
symbol as prefix. Without a leading +
or
-
the flags will replace the flags of the delivery agent.
use_quotes
Data type: Boolean
A boolean that indicates if the flags should be quoted
(using m4 quotes). If this argument is true
, then the flags will be
enclosed in and ' symbols in the generated output file. Valid options:
trueor
false`.
Default value: true
sendmail::mc::ostype
Add the OSTYPE
macro to the sendmail.mc file.
Examples
Set the OSTYPE
to Debian
sendmail::mc::ostype { 'Debian': }
Parameters
The following parameters are available in the sendmail::mc::ostype
defined type:
ostype
Data type: String
The type of operating system as a string. The value is used
to add the OSTYPE
macro to the generated sendmail.mc file. This will
include the m4 file with operating system specific settings.
Default value: $name
sendmail::mc::queue_group
Add the QUEUE_GROUP
macro to the sendmail.mc file.
Examples
Create a queue group named gmailcom
for single recipient delivery
sendmail::mc::queue_group { 'gmailcom':
flags => 'f',
interval => '60m',
path => '/var/spool/mqueues/gmail',
recipients => 1,
}
Parameters
The following parameters are available in the sendmail::mc::queue_group
defined type:
queue_group
Data type: String
The name of the queue group.
Default value: $name
flags
Data type: Optional[String]
Flags for the queue group. Currently only the f
flag is
supported and causes Sendmail to create one queue process for each queue
directory in the group.
Default value: undef
interval
Data type: Optional[String]
The interval specifies the time interval between queue runs
for the queue group. The parameter value should be an integer and
a letter (e.g. 10m
). The letters w
(week), d
(day), h
(hour),
m
(minute) and s
(second) are allowed.
Default value: undef
jobs
Data type: Optional[Integer]
This parameter limits the number of queue entries that will be processed in a single queue run.
Default value: undef
nice
Data type: Optional[Integer]
Set the nice-level for the queue group processor. Using a positive number will increase the nice-level by the given number. This results in the process to run with a reduced priority.
Default value: undef
recipients
Data type: Optional[Integer]
The number of recipients that are processed in a single delivery before splitting.
Default value: undef
runners
Data type: Optional[Integer]
The number of queue runners to lauch for this queue group.
Default value: undef
path
Data type: Optional[Stdlib::Absolutepath]
The location of the queue directory for this queue group. The
parameter must be an absolute path and must be a subdirectory of the
default queue directory configured by the QueueDirectory
option.
Default value: undef
sendmail::mc::versionid
Add the VERSIONID
macro to the sendmail.mc file.
Examples
Set the VERSIONID
to the value generic
sendmail::mc::versionid { 'generic': }
Parameters
The following parameters are available in the sendmail::mc::versionid
defined type:
versionid
Data type: String
The identifier (a string) to set in the sendmail.mc file.
Default value: $name
sendmail::mc::virtuser_domain
Add the VIRTUSER_DOMAIN
macro to the sendmail.mc file.
Examples
sendmail::mc::virtuser_domain { 'example.net': }
Parameters
The following parameters are available in the sendmail::mc::virtuser_domain
defined type:
domainname
Data type: Stdlib::Fqdn
The name of the domain to use with
FEATURE(virtusertable)
. This can be used multiple times to set more
than one domain name.
Default value: $name
sendmail::userdb::entry
The type has an internal dependency to rebuild the database file.
Examples
Add an entry to the userdb
sendmail::userdb::entry { 'fred:maildrop':
value => 'fred@example.org',
}
Parameters
The following parameters are available in the sendmail::userdb::entry
defined type:
ensure
Data type: Enum['present','absent']
Used to create or remove the userdb db entry. Valid options:
present
, absent
.
Default value: 'present'
key
Data type: String
The key used by Sendmail for the lookup. This normally is in
the format user:maildrop
or user:mailname
where user is the a local
username.
Default value: $name
value
Data type: Optional[String]
The value for the given key. For the userdb map this is typically a single mailaddress or a compound list of addresses separated by commas.
Default value: undef
sendmail::virtusertable::entry
The type has an internal dependency to rebuild the database file.
Examples
Rewrite info@example.com
to fred@example.com
sendmail::virtusertable::entry { 'info@example.com':
value => 'fred@example.com',
}
Rewrite all users in the example.org
domain to a local user
sendmail::virtusertable::entry { '@example.org':
value => 'barney',
}
Parameters
The following parameters are available in the sendmail::virtusertable::entry
defined type:
ensure
Data type: Enum['present','absent']
Used to create or remove the virtusertable db entry. Valid
options: present
, absent
.
Default value: 'present'
key
Data type: String
The key used by Sendmail for the lookup. This is normally a mail address or a mail address without the user part.
Default value: $name
value
Data type: Optional[String]
The value for the given key. For the virtusertable map this is typically a local username or a remote mail address.
Default value: undef
Functions
sendmail::canonify_array
Type: Puppet Language
Rewrite the input array the following way:
- strip spaces from the beginning and end of each string
- remove duplicate entries
- sort the result
sendmail::canonify_array(Array[String] $arg)
Rewrite the input array the following way:
- strip spaces from the beginning and end of each string
- remove duplicate entries
- sort the result
Returns: Array[String]
array of canonified strings
arg
Data type: Array[String]
array of strings to canonify
Data types
Sendmail::DHParam
The valid number of bits for DH params.
Alias of
Variant[Enum['512','1024','2048'], Stdlib::Absolutepath]
Sendmail::Deliverymode
The supported delivery modes for Sendmail.
Alias of
Enum['b', 'background', 'd', 'deferred', 'i', 'interactive', 'q', 'queueonly']
Sendmail::Loglevel
The supported loglevels.
Alias of
Variant[Pattern[/^\d+$/], Integer]
Sendmail::Messagesize
A message size specification in bytes, kb or Mb.
Alias of
Pattern[/^[0-9]*\s*([kM][bB])?$/]
Sendmail::Timeout
A timeout specification in seconds or minutes.
Alias of
Pattern[/^[0-9]+(s|m)?$/]
2023-11-27 - Release 4.1.0
Fixed
- A long standing bug where the generation of entries in the authinfo file used the wrong quotes has been fixed.
Enhancements
- The defined type
sendmail::mc::feature
now acceptsundef
elements for theargs
array. They translate into empty parameters (e.g. two consecutive commas in them4
code).
2023-08-10 - Release 4.0.0
Breaking changes
- Support for Puppet 6 has been dropped.
- Stdlib version must be 9.0.0 or higher.
Enhancements
- Support for Puppet 8 has been added.
- Support for Concat 9.x has been added.
- Support for Stdlib 9.x has been added.
2023-04-24 - Release 3.3.0
Enhancements
- Support Concat 8.x module.
- Fix various puppet-lint issues.
2022-05-05 - Release 3.2.0
Fixed
- The module dependencies on additional modules have been fixed.
Enhancements
- The class documentation has been updated to Puppet Strings and a `
REFERENCE.md
is now included.
2021-11-27 - Release 3.1.0
Features
- New defined type
sendmail::mc::virtuser_domain
to manage the domains to use with FEATURE(virtusertable).
2021-09-30 - Release 3.0.2
Fixed
- Fix stdlib 8.x requirement
2021-08-27 - Release 3.0.1
Updated
- Add support for Debian 11
- Allow stdlib 8.0.0
2021-07-09 - Release 3.0.0
Fixed
- For FreeBSD the path of the aliases file has been updated to
/etc/mail/aliases
to reflect the system standard.
Updated
- Support for Puppet 7 has been added.
- The version dependencies for the
stdlib
andconcat
modules have been updated to reflect the usage of newer Puppet versions. - Sendmail queue groups are implemented with
sendmail::mc::queue_group
.
Removed
- Support for Puppet 5 has been removed.
- Support for Debian 8, Ubuntu 14.04, RedHat 6, CentOS 6, Oracle Linux 6 and FreeBSD 10 has been removed.
2018-10-28 - Release 2.0.0
Summary
This is a major update that adds support for Puppet 6 and drops support for Puppet 3. Legacy code for Puppet 3 has been removed. Classes and defined types use data types for validation now.
Breaking changes
- Rename parameter
domain
todomain_name
forsendmail::mc::domain
to prevent clash with fact. - Rename parameter
domain
todomain_name
forsendmail::mc::generics_domain
to prevent clash with fact. - Rename parameter
domain
todomain_name
forsendmail::mc::ldaproute_domain
to prevent clash with fact. - The defined type
sendmail::mc::trust_auth_mech
has been removed and a class with the same name has been added.
Fixed
- Sendmail on Ubuntu now correctly includes the
starttls.m4
file where some TLS related defaults are set. - The previously missing documentation for the
tls_srv_options
parameter has been added.
Updated
- The version dependencies for the
stdlib
andconcat
modules have been updated to reflect the usage of newer Puppet versions.
Removed
- Support for Puppet 3 has been removed.
- Support for Debian 7 and Ubuntu 17.10 have been removed.
2018-06-24 - Release 1.5.0
Summary
This release contains a bugfix related to the sendmail_version
fact. It also adds support for Ubuntu-18.04 Bionic Beaver.
Features
- The module has been tested to work on Ubuntu-18.04 Bionic Beaver.
Bugfixes
- Under certain conditions a Puppet run could lead to a
User unknown
error message in the mail log. This was caused by the execution of the Sendmail binary to determine thesendmail_version
fact. The fact now uses a reduced log level to prevent that message.
2018-06-03 - Release 1.4.1
Summary
An unused backup file was removed from the module.
2018-06-03 - Release 1.4.0
Summary
This release adds an new defined type to set generic domains. The sendmail version fact has also been improved to be more resistant to DNS failures.
Features
- New defined type
sendmail::mc::generics_domain
to manage the domains to use with FEATURE(genericstable).
Bugfixes
- Increase stability of
sendmail_version
fact. The previous implementation sometimes failed to return the correct version number when a DNS lookup timed out.
2018-05-16 - Release 1.3.2
Summary
Remove unintended code that was included in 1.3.1.
2018-05-16 - Release 1.3.1
Summary
The module dependencies have been updated to include current releases of the concat module. No functional changes were made.
2018-02-19 - Release 1.3.0
Summary
A feature release that adds a new class parameter.
Features
- The new parameter
features
was added to thesendmail
class. This enables additional sendmail features directly within the mail class.
2018-02-04 - Release 1.2.0
Summary
A small update that fixes a minor bug and includes an updated compatibility matrix.
Bugfixes
- Improved compatibility of the
sendmail_version
fact when other mailers are installed.
2017-05-08 - Release 1.1.1
Summary
This release fixes a bug in the validation code of the sendmail::nullclient
class.
Bugfixes
- The
sendmail::nullclient
class could incorrectly cause a validation error when version 4.14 or later of thestdlib
module was used. This error has been fixed.
2017-01-24 - Release 1.1.0
Summary
This release adds some milter related improvements and rearranges TLS related parameters in the generated configuration file.
Features
- The
flags
parameter ofsendmail::mc::milter
allows the empty string value now. This value indicates that a milter failure should be treated as if the milter wasn't configured. - Also the boolean parameter
enable
was added tosendmail::mc::milter
. A value oftrue
(default) will automatically enable the milter for all daemons. A value offalse
will only define the milter in the config file. - Milter and TLS related config file options are now grouped together in the generated
sendmail.mc
file.
2016-09-10 - Release 1.0.0
Summary
With this 1.0.0 release the module interface is considered stable. The requirements have been updated to Puppet 3.7 or Puppet Enterprise 3.7.
Features
- Add Ubuntu 16.04 (Xenial Xerus) to the list of supported operating systems.
Bugfixes
- A timeout for the sendmail version fact has been added (fixes #10).
2016-04-27 - Release 0.7.0
Summary
A small release that fixes a metadata warning and introduces the domain_name
parameter.
Features
- Add parameter
domain_name
to allow setting the fully qualified domain name that Sendmail should use. This may be useful in rare conditions where Sendmail runs on a multihomed machine and picks the wrong name.
Bugfixes
- Update metadate dependencies to use a dash instead of a slash character. This fixes a dependency warning on newer Puppet releases.
2016-04-10 - Release 0.6.1
Summary
This release contains the fix for a problem with the group ownership of the aliases file on FreeBSD. Also some internal tests were rewritten to use the rspec-puppet-facts gem.
Bugfixes
- Fix group ownership of aliases file on FreeBSD.
2016-03-25 - Release 0.6.0
Summary
This release adds FreeBSD compatibility. It also adds a new class to configure Sendmail related timeouts in a single place.
Features
- Add FreeBSD 10 to the list of supported operating systems.
- Add class
sendmail::mc::timeouts
to conveniently specify most of the timeouts in one place. - The class
sendmail::privacy_flags
has been renamed tosendmail::mc::privacy_flags
.
Bugfixes
- The
mailx
package is no longer managed by the Sendmail module. The user should be free to decide which MUA to install.
2016-02-23 - Release 0.5.0
Summary
The release fixes some bugs. It has also been verified to run on Ubuntu 15.10.
Features
- Add Ubuntu 15.10 (Wily Werewolf) to the list of supported operating systems.
Bugfixes
- Fix intermittent change of parameter order in some cases.
- Fix file owner and group on RedHat family.
- Fix errors in logfile when
/usr/sbin/sendmail
isn't really Sendmail.
2016-02-11 - Release 0.4.0
Summary
This release contains some enhancements. See the following items for details.
Features
- Add configuration parameters
enable_ipv4_msa
andenable_ipv6_msa
to thesendmail::nullclient
class to configure the MSA for IPv4 and IPv6. - Define privacy flags for the daemon with the help of the
sendmail::privacy_flags
class. - Add parameter
daemon_name
to thesendmail::mc::daemon_options
type. This allows reusing the same name for multiple daemon option enties. - Allow a string parameter for
sendmail::mc::feature
if the feature requires only a single argument.
2016-01-21 - Release 0.3.0
Summary
This release adds support for the RedHat family and also includes some minor new features.
Features
- Add RedHat/CentOS 6/7 to the list of supported operating systems.
- New parameter
enable_msp_trusted_users
to activate theuse_ct_file
feature insubmit.mc
. - Allow strings and arrays for the
input_milter
parameter of thesendmail::mc::daemon_options
defined type.
Bugfixes
- The nullclient setup didn't allow setting the content of the trusted users file. This has been fix by adding the
trusted_users
parameter to thesendmail::nullclient
class.
2016-01-14 - Release 0.2.0
Summary
This release fixes a bug that can lead to an aborted Puppet run when a STARTTLS configuration is deployed to a machine where Sendmail is not yet installed. It also includes support for Ubuntu and some minor new features.
Features
- Add Ubuntu 14.04 (Trusty Tahr) and 15.04 (Vivid Vervet) to the list of supported operating systems.
- Improvement and documentation of the
sendmail::authinfo::entry
defined type. - Add parameter
max_message_size
for thesendmail
andsendmail::nullclient
classes. - Rename daemon in nullcient setup from
MTA
toMSA
.
Bugfixes
- Improve handling of an undefined
$::sendmail_version
fact. Using this fact returns an undefined value if Sendmail is not yet installed. For some configurations Puppet may need to run twice before the desired configuration is reached.
2015-12-28 - Release 0.1.0
Summary
Initial release.
Dependencies
- puppetlabs/stdlib (>= 9.0.0 < 10.0.0)
- puppetlabs/concat (>= 7.0.0 < 10.0.0)
- puppetlabs/augeas_core (>= 1.2.0 < 2.0.0)
- puppetlabs/mailalias_core (>= 1.1.0 < 2.0.0)
Copyright (c) 2015, Stefan Möding All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.