From 585837f2a0e69bf29feb56b155562e96396e3933 Mon Sep 17 00:00:00 2001 From: jim-p Date: Tue, 29 Mar 2011 10:23:53 -0400 Subject: Add a field to the postfix forwarder package to set the max message size. --- config/postfix/postfix.inc | 6 +++++- config/postfix/postfix.xml | 18 +++++++++++++++++- 2 files changed, 22 insertions(+), 2 deletions(-) (limited to 'config') diff --git a/config/postfix/postfix.inc b/config/postfix/postfix.inc index f100a937..cf470c8f 100644 --- a/config/postfix/postfix.inc +++ b/config/postfix/postfix.inc @@ -35,9 +35,12 @@ function sync_package_postfix() { $relay_domains = ""; $transport = ""; + $message_size_limit = "10240000"; if (is_array($config['installedpackages']['postfix']['config'])) { foreach ($config['installedpackages']['postfix']['config'] as $postfix_config) { + if (isset($postfix_config['message_size_limit'])) + $message_size_limit = $postfix_config['message_size_limit']; if (is_array($postfix_config['row'])) { foreach ($postfix_config['row'] as $postfix_row) { $relay_domains .= ' ' . $postfix_row['domain']; @@ -53,7 +56,8 @@ function sync_package_postfix() { "transport_maps = hash:/usr/local/etc/postfix/transport\n" . "local_recipient_maps =\n" . "mydestination =\n" . - "mynetworks_style = host\n"; + "mynetworks_style = host\n" . + "message_size_limit = {$message_size_limit}\n"; conf_mount_rw(); diff --git a/config/postfix/postfix.xml b/config/postfix/postfix.xml index e1e89bae..292ca595 100644 --- a/config/postfix/postfix.xml +++ b/config/postfix/postfix.xml @@ -42,7 +42,7 @@ Describe your package requirements here Currently there are no FAQ items provided. postfix - 1.0 + 1.1 Services: Postfix Forwarder /usr/local/pkg/postfix.inc @@ -62,6 +62,22 @@ 0755 + + Posftix General Settings + listtopic + + + Maximum message size + message_size_limit + input + + This setting governs the largest message size that will be accepted by this mail server. Ensure you have enough space to accommodate this size, and ensure this setting matches or is lower than the destination server(s).<br/>Default: 10240000 (10MB). + + + + Domains to Forward + listtopic + Forwarding none -- cgit v1.2.3