Email/SMTP config forces to define an user and password, should be optional
We are using google as our relay SMTP server. We have to use that server without user and pass.
Talkyard uses fake mail if user or password is not defined: https://github.com/debiki/talkyard/blob/67c11a773f8975410663b41723ece21214076e1c/app/debiki/Mailer.scala#L92
Could we make that parameters optional?
- 8 replies
- KajMagnus @KajMagnus2018-10-22 14:14:06.195Z
Can I ask, how do you authenticate against Google's mail server? Is it maybe by IP address, as described here?: https://support.google.com/a/answer/2956491?hl=en step 7:
7. In the Authentication section, check one or both boxes to set an authentication method:
- Only accept mail from the specified IP addresses—The system only accepts mail sent from these IP addresses as coming from your domains.
- Require SMTP Authentication—Enforces the use of SMTP authentication to identify the sending domain. Using this option requires your clients to connect via TLS.
Anyway since apparently controlling an IP address works fine, for authentication (i didn't know that until now when I read Google's docs), then yes the username and password settings should be made optional.
(Thanks for linking to the source :- ) saved some time for me)
We use G-Suite, https://support.google.com/a/answer/176600?hl=en.
I have checked to send an email using the server without auth and works correctly. I tried to use some random user/pass, but it does not work.
BTW, any docs of how to build a custom image?
I have been trying building with sbt, docker, etc but no luck
- In reply toadrianlzt⬆:KajMagnus @KajMagnus2018-10-23 05:32:53.386Z
I tried to use some random user/pass, but it does not work.
What's the error message?
If you type
docker-compose logs app > dc-logs-app.txt, maybe you'd like to send me a private message with the
dc-logs-app.txtfile? Then i can check for error messages.
Anyway, I'll do this in the next release, if there's no username: https://stackoverflow.com/a/19115844/694469, that is:
And I'll skip this line:
apacheCommonsEmail.setAuthenticator(new acm.DefaultAuthenticator(userName, password))
- Progresswith handling this problem
- @KajMagnus marked this topic as Planned 2018-10-23 04:08:49.035Z.
- KajMagnus @KajMagnus2018-11-07 12:24:02.484Z
Now I've removed the requirement to specify username and password. Your server should have auto-upgraded to the new version, 0.6.15, with this fixed, last night (Tue –> Wed). Would you like to see if works for you? (Sorry this took long. That's because there were some other changes that took long to review & test, in the same release.)
- @KajMagnus marked this topic as Started 2018-11-07 12:24:05.626Z.
- @KajMagnus marked this topic as Done 2018-11-09 15:37:39.207Z.