From 2f7e5bd45aaa68be4753e72dec5b16ab3e7542b2 Mon Sep 17 00:00:00 2001 From: urosj Date: Wed, 2 Aug 2017 18:43:59 +0200 Subject: [PATCH] Added additional instruction to set destination recipient limit to 1, so it calls program once for each recipient. --- cmd/autoresponder.go | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/cmd/autoresponder.go b/cmd/autoresponder.go index ce0dbba..dc04b33 100644 --- a/cmd/autoresponder.go +++ b/cmd/autoresponder.go @@ -27,6 +27,10 @@ package main // autoresponder unix - n n - - pipe // flags=Fq user=autoresponder argv=/usr/local/sbin/autoresponder -s ${sender} -r ${recipient} -S ${sasl_username} -C ${client_address} // +// Set additional postfix parameter: +// postconf -e 'autoresponder_destination_recipient_limit = 1' +// service postfix restart +// // // Written by Uros Juvan 2017 @@ -44,7 +48,7 @@ import ( "log/syslog" ) -const VERSION = "1.0.0005" +const VERSION = "1.0.0006" const DEBUG = true const RESPONSE_DIR = "/var/spool/autoresponder/responses" @@ -549,6 +553,10 @@ func main() { At the end of file append the following two lines: autoresponder unix - n n - - pipe flags=Fq user=autoresponder argv=/usr/local/sbin/autoresponder -s ${sender} -r ${recipient} -S ${sasl_username} -C ${client_address} + + Set additional postfix parameter: + postconf -e 'autoresponder_destination_recipient_limit = 1' + service postfix restart `) os.Exit(0) }