Zitat von "cont...@rusanu.com" <cont...@rusanu.com>:
Is there a way to configure postfix to use a relay only if direct delivery is rejected? The case being a web application that has to send notification to subscribers, but some servers reject the connection (app IP originates from AWS EC2). I want those cases to be retried using a paid SMTP relay like authsmtp.com. However I don't want to use the relay for everything since it costs per mail.
If it is rejected with a permanent error code (5xx) no retry an no fallback will happen. This is required by RFC. If the reject is with some temporary reject code or the connection is not accepted at all you need the fallback_relay parameter.
Regards Andreas