Haraka
Haraka copied to clipboard
Outbound Forwarding Docs/Help
I'm trying to follow instructions from https://haraka.github.io/plugins/queue/smtp_forward/ and related pages to have a new Haraka server accept outgoing mail and forward everything to another specific server. (Eventually, to implement DKIM signing)
I thought all I had to do was enable TLS and smtp_forward. Maybe I confused this with some of the 'outbound' settings. But the result is that Haraka accepts the message, then prints things like this:
[INFO] [-] [core] [outbound] Sending email as a transaction
[INFO] [-] [core] [outbound] Processing delivery for domain: example.com
[NOTICE] [core] queue code=OK msg="Message Queued ..."
[INFO] [-] [core] loading tls.ini
[INFO] [outbound] Looking up A records ...
At this point it looks up the recipient domain and attempts to deliver the mail instead of forwarding to my server.
Have I encountered some common pitfall in the configuration? Is there a better way to explain this in the smtp_forward documentation?
Should I be using Relay Force Route instead? And is there any way to catch all domains instead of listing specific domains?
There is a third similar feature mentioned at https://haraka.github.io/core/Outbound/ where it says to "use the get_mx hook documented above". Is that necessary?
in the smtp_forward config file, did you set enable_outbound=true
? If you don't, then mails get delivered by Haraka outbound.
Yes, I did. The only change I see when set to true is an extra message on startup that this feature will be deprecated in v3. It still tries to deliver outbound mail via MX servers instead of the forward server.
Currently looking at the get_mx hook as described here https://baudehlo.wordpress.com/2016/07/26/setting-up-haraka-to-send-to-mailchimpsendgridses-etc/
The get_mx hook works. I disabled the smtp_forward plugin.
My conclusions so far: The smtp_forward plugin is for host_list inbound mail only??? Documentation needs improvement. Also, the get_mx hook should have a documented implementation or a configurable plugin included so that this behavior can be properly set up using ini files rather than custom plugin code.
The smtp_forward plugin is for host_list inbound mail only
Almost, yes. It's for any mail determined to be "inbound," whether via host_list or another plugin.
Documentation needs improvement.
Sorry, we're aware.
Also, the get_mx hook should have a documented implementation or a configurable plugin included
PRs are welcome.
Hi! I need to setup haraka as a email proxy. I'm noob in SMTP stuffs but, basically I want to make my server to the emails it has to send, forwards it to an gmail account, and that gmail account to deliver's them (a noreply@mydomain,com account that is with google workspace)
Not sure if is the same as Outbound forwarding (this issue)? there is any easy doc for this? I guess is to make haraka to connect via SMTP to gmail and makes that account to deliver the email
Gonna try with smtp_forward plugin that it seems to be the one I need, but would be nice a tutorial for quick setup this for gmail case
#3119 restored the ability of smtp_forward to deliver on outbound, matching the docs.
This worked for me, but I ran into several problems updating to v3.0. Here is a tutorial for anyone trying to implement smtp_forward
.
https://www.miqrogroove.com/blog/2023/smart-host-haraka-v3/