Add smtp_accept_max and smtp_accept_max_per_host
Allow callers to optionally set smtp_accept_max and smtp_accept_max_per_host options for tuning systems to handle higher connection volumes. Also fix the config template's conditional for queue_smtp_domains since it defaults to undef but was previously checked against "" instead. Change-Id: I5519f6c28c81a6f40c78551ac318b91cacfc04fb
This commit is contained in:
parent
4f1c9531bc
commit
5a09f46999
|
@ -21,15 +21,17 @@
|
||||||
# http://www.exim.org/exim-html-current/doc/html/spec_html/index.html
|
# http://www.exim.org/exim-html-current/doc/html/spec_html/index.html
|
||||||
|
|
||||||
class exim(
|
class exim(
|
||||||
$local_domains = '@',
|
$local_domains = '@',
|
||||||
$mailman_domains = [],
|
$mailman_domains = [],
|
||||||
$queue_interval = '30m',
|
$queue_interval = '30m',
|
||||||
$queue_run_max = '5',
|
$queue_run_max = '5',
|
||||||
$queue_smtp_domains = undef,
|
$queue_smtp_domains = undef,
|
||||||
$routers = [],
|
$routers = [],
|
||||||
$smarthost = false,
|
$smarthost = false,
|
||||||
$sysadmins = [],
|
$sysadmins = [],
|
||||||
$transports = [],
|
$transports = [],
|
||||||
|
$smtp_accept_max = undef,
|
||||||
|
$smtp_accept_max_per_host = undef,
|
||||||
) {
|
) {
|
||||||
|
|
||||||
include ::exim::params
|
include ::exim::params
|
||||||
|
|
|
@ -312,9 +312,9 @@ queue_run_max = <%= @queue_run_max %>
|
||||||
# to be queued in this way, and is equivalent to setting
|
# to be queued in this way, and is equivalent to setting
|
||||||
# queue_smtp_domains to "*". See also hold_domains and queue_domains.
|
# queue_smtp_domains to "*". See also hold_domains and queue_domains.
|
||||||
|
|
||||||
<% if @queue_smtp_domains != "" -%>
|
<% unless ["", nil, :undef].include?(@queue_smtp_domains) -%>
|
||||||
queue_smtp_domains = <%= @queue_smtp_domains %>
|
queue_smtp_domains = <%= @queue_smtp_domains %>
|
||||||
<% end %>
|
<% end -%>
|
||||||
|
|
||||||
<% if @mailman_domains.length > 0 -%>
|
<% if @mailman_domains.length > 0 -%>
|
||||||
# Home dir for your Mailman installation -- aka Mailman's prefix
|
# Home dir for your Mailman installation -- aka Mailman's prefix
|
||||||
|
@ -349,6 +349,16 @@ MM_LISTCHK=MM_HOME/lists/${lc::$local_part}/config.pck
|
||||||
|
|
||||||
dns_ipv4_lookup = *.gmail.com : *.google.com
|
dns_ipv4_lookup = *.gmail.com : *.google.com
|
||||||
|
|
||||||
|
<% unless ["", nil, :undef].include?(@smtp_accept_max) -%>
|
||||||
|
# simultaneous incoming connections
|
||||||
|
smtp_accept_max = <%= @smtp_accept_max %>
|
||||||
|
<% end -%>
|
||||||
|
|
||||||
|
<% unless ["", nil, :undef].include?(@smtp_accept_max_per_host) -%>
|
||||||
|
# connections from one host
|
||||||
|
smtp_accept_max_per_host = <%= @smtp_accept_max_per_host %>
|
||||||
|
<% end -%>
|
||||||
|
|
||||||
######################################################################
|
######################################################################
|
||||||
# ACL CONFIGURATION #
|
# ACL CONFIGURATION #
|
||||||
# Specifies access control lists for incoming SMTP mail #
|
# Specifies access control lists for incoming SMTP mail #
|
||||||
|
|
Loading…
Reference in New Issue