If that server has also a NS role, the "extravaganza" task is questionable.

-----Original Message-----
From: owner-postfix-us...@postfix.org [mailto:owner-postfix-us...@postfix.org] 
On Behalf Of Kirill Peskov
Sent: Thursday, July 2, 2015 6:43 PM
To: postfix-users@postfix.org
Subject: Any elegant way to count all the incoming messages?

Dear postfix gurus,

Could you, please, suggest the method to setup a message counter on
SMTP, so every incoming message regardless exact content of To: Cc: or
Bcc: fields (e.g. one SMTP transaction) would increase the counter by
one or call corresponding bash script able to do that? I've got
development task to create a sort of ephemeral MX which should run only
limited amount of time and/or process only limited amount of messages.
After it reaches MAX_MESSAGES or MAX_UPTIME (whatever comes first), the
server should check if all the queues are empty, stop postfix and reboot
or shutdown itself (don't ask me why do I need such extravaganza, ;)
that's simply must be a part of our continuous integration workflow).


Thanx in advance,
Kirill


Reply via email to