On Wed, Oct 21, 2020 at 04:03:32PM +0800, Luan Shengde wrote:
On Wed, Oct 21, 2020 at 03:01:28PM +0800, Wu Fengguang wrote:
On Wed, Oct 21, 2020 at 02:51:00PM +0800, Luan Shengde wrote:
+def check_send_mail(mail_info)
- if ENV['SMTP_REGION'] == 'internet-smtp'
Perhaps no need to test that. Just use
mail_info['from'] ||= ENV['FROM_ADDRESS']
And let the 2 containers pass different FROM_ADDRESS env into docker.
for send internet mail, the FROM_ADDRESS must be same to the user_name setted in smtp
Then let it fail. Why would the client set "from:" for Internet email at all?
我的意思, 我们自己的REST client, 就不填"from:"字段了。这样可行?
because the smtp setting need authentication with a email_addresss if you want to send a internet via the smtp setting, the from must be same to the user_name in smtp setting. if not the authentication will fail.
unless build authentication for user defined 'form:' in smtp setting for sending internet mail, or else send internet mail will end with failure.
Thanks Luan Shengde
Thanks, Fengguang