diff --git a/postfix.grok b/postfix.grok index 323d2c1..8d107db 100644 --- a/postfix.grok +++ b/postfix.grok @@ -120,6 +120,9 @@ POSTFIX_SCACHE_TIMESTAMP statistics: start interval %{SYSLOGTIMESTAMP:postfix_sc # verify patterns POSTFIX_VERIFY_CACHE cache %{DATA} %{POSTFIX_VERIFY_CLEANUP_TYPE:postfix_verify_cleanup_type} cleanup: retained=%{INT:postfix_verify_cache_retained} dropped=%{INT:postfix_verify_cache_dropped} entries +# local patterns +POSTFIX_LOCAL_DELIVERY %{POSTFIX_KEYVALUE} status=%{STATUS_WORD:postfix_status}( \(%{GREEDYDATA:postfix_local_response}\))? + # aggregate all patterns POSTFIX_SMTPD %{POSTFIX_SMTPD_CONNECT}|%{POSTFIX_SMTPD_DISCONNECT}|%{POSTFIX_SMTPD_LOSTCONN}|%{POSTFIX_SMTPD_NOQUEUE}|%{POSTFIX_SMTPD_PIPELINING}|%{POSTFIX_TLSCONN}|%{POSTFIX_WARNING}|%{POSTFIX_SMTPD_PROXY}|%{POSTFIX_KEYVALUE} POSTFIX_CLEANUP %{POSTFIX_CLEANUP_MESSAGEID}|%{POSTFIX_CLEANUP_MILTER}|%{POSTFIX_CLEANUP_PREPEND}|%{POSTFIX_WARNING}|%{POSTFIX_KEYVALUE} @@ -140,7 +143,7 @@ POSTFIX_POSTDROP %{POSTFIX_WARNING} POSTFIX_SCACHE %{POSTFIX_SCACHE_LOOKUPS}|%{POSTFIX_SCACHE_SIMULTANEOUS}|%{POSTFIX_SCACHE_TIMESTAMP} POSTFIX_TRIVIAL_REWRITE %{POSTFIX_WARNING} POSTFIX_TLSMGR %{POSTFIX_WARNING} -POSTFIX_LOCAL %{POSTFIX_SMTP_DELIVERY}|%{POSTFIX_WARNING} +POSTFIX_LOCAL %{POSTFIX_LOCAL_DELIVERY}|%{POSTFIX_WARNING} POSTFIX_VIRTUAL %{POSTFIX_SMTP_DELIVERY} POSTFIX_ERROR %{POSTFIX_ERROR_ANY} POSTFIX_POSTSUPER %{POSTFIX_POSTSUPER_ACTION}|%{POSTFIX_POSTSUPER_SUMMARY} diff --git a/test/local_0001.yaml b/test/local_0001.yaml index 44f8f0c..9d9d091 100644 --- a/test/local_0001.yaml +++ b/test/local_0001.yaml @@ -4,4 +4,4 @@ results: postfix_queueid: 2A22C263F6 postfix_keyvalue_data: "to=user@hostname.example.com, orig_to=root@localhost, relay=local, delay=0.07, delays=0.04/0/0/0.03, dsn=2.0.0," postfix_status: sent - postfix_smtp_response: "delivered to command: procmail -a \"$EXTENSION\"" + postfix_local_response: "delivered to command: procmail -a \"$EXTENSION\"" diff --git a/test/local_0002.yaml b/test/local_0002.yaml index b0fd4a7..b2924a0 100644 --- a/test/local_0002.yaml +++ b/test/local_0002.yaml @@ -4,4 +4,4 @@ results: postfix_queueid: 892A0205B6 postfix_keyvalue_data: "to=ghdsgfhdslfh@localhost, relay=local, delay=0.05, delays=0.02/0/0/0.02, dsn=5.1.1," postfix_status: bounced - postfix_smtp_response: "unknown user: \"ghdsgfhdslfh\"" + postfix_local_response: "unknown user: \"ghdsgfhdslfh\""