Smart Host to Selected Domains
Hello to everyone
There are many topics about this topic.
I read all topics
but a little difficult for novice or intermediate users like me
now I'll tell you what I want
I have 14 domains in cpanel
there are 3 e-commerce sites in them and they have heavy e-mail traffic.
I want to use a smart host for only 3 domains. I don't want to use it for all domains.
I think this is possible, but I did not understand it well.
1-
works with these settings
but for all domains
2-
Turn off the smart host feature and
when you make these settings
send smart host from only one email address you added
but the email is waiting in a queue for a bit, but then it goes.
but you can send it from a single email address. I could not add a second or third email address.
other emails go normally. The email I added is sent via the smart host.
How should I organize this scenario?
only the domains I want can send as smart hosts.
there are topics related to this in the forum but experienced user level information. I would appreciate it if you could help with a simpler expression.
Best regards
| @AUTH@ company_login: driver = plaintext public_name = LOGIN client_send = : MY-USERNAME : MY-PASS |
| @ROUTERSTART@ send_via_company: driver = manualroute domains = ! +local_domains transport = company_smtp route_list = * company.mail.com |
| @TRANSPORTSTART@ company_smtp: driver = smtp port = 25 hosts = company.mail.com hosts_require_auth = company.mail.com |
| @AUTH@ company_login: driver = plaintext public_name = LOGIN client_send = : MY-USERNAME : MY-PASS |
| @ROUTERSTART@ send_via_company: driver = manualroute domains = ! +local_domains senders = support@mydomain.com (that's the only difference) transport = company_smtp route_list = * company.mail.com |
| @TRANSPORTSTART@ company_smtp: driver = smtp port = 25 hosts = company.mail.com hosts_require_auth = company.mail.com |
-
Hey there! I don't believe there is going to be an easier method than the things that have already been posted on the forum in the past. cPanel doesn't natively support this type of mail handling, so any work to get this configuration applied will involve advanced editing of the Exim configuration and router systems. 0 -
super, wouldn't anyone write an example here? 0 -
I have read all of these topics. There is no answer I'm looking for. for example here you can send emails from 1 domain with smart host. I wish we could add domains with commas here. Section: PREROUTERS
{mydomain.com, domain2.com, domain3.} For example, is something like this possible? comma doesnt work, tried it. Is there a command that works?send_via_dmail: driver = manualroute domains = ! +local_domains condition = "${if eq {$sender_address_domain}{mydomain.com}{true}{false}}" ignore_target_hosts = 0.0.0.0 : 127.0.0.0/8 headers_add = "${perl{mailtrapheaders}}" transport = dmail_smtp route_list = * outbound.dmail.com 0 -
Unfortunately it isn't as simple as one command as there will need to be custom work performed to get that configured. 0 -
well then. Can anyone give other information about the subject I am looking for. 0 -
Solution Specify only certain domains (of the sender email address) to send through the smarthost Easy Settings Replace the underlined text with your own settings Exim Configuration Manager + Advanced editor
create a file /etc/exim/authorized_senders.txt. Add domain names in below format into that file:@AUTH@ company_login: driver = plaintext public_name = LOGIN client_send = : MY-USERNAME : MY-PASS @ROUTERSTART@ send_via_company: driver = manualroute domains = ! +local_domains transport = company_smtp route_data = ${lookup{$sender_address_domain}lsearch*{/etc/exim/authorized_senders.txt}} @TRANSPORTSTART@ company_smtp: driver = smtp port = 25 hosts = company.mail.com hosts_require_auth = company.mail.com
Exim Restart If you still don't understand, write it here. I will try to help.domain1.com: company.mail.com domain2.com: company.mail.com 0
Please sign in to leave a comment.
Comments
7 comments