Reputation: 275
I'm using jenkins docker image. I want to configure my mail to jenkins so that I can get mail regarding all builds.
what changes should i make in docker-image so that i can able to send mail to myself?
I'm getting this error
com.sun.mail.smtp.SMTPSendFailedException: 530 5.7.57 SMTP; Client was not
authenticated to send anonymous mail during MAIL FROM
[BM1PR01CA0088.INDPRD01.PROD.OUTLOOK.COM]
command I used to run docker image is :
$ docker run -u 0 --name myjenkins1 -p 8081:8080 -p 50001:50000 -v jenkins_home:/var/jenkins_home --env JAVA_ARGS="-Djava.awt.headless=true -Dmail.smtp.starttls.enable=true" jenkins
Upvotes: 1
Views: 2856
Reputation: 1649
The issue here stems from your e-mail provider rather than anything to do with Docker or Jenkins. See this post from Microsoft about direct sends...
This indicates that you are connecting to the SMTP client submission endpoint (smtp.office365.com), which can't be used for direct send. For direct send, use the MX endpoint for your Office 365 tenant, which ends with "mail.protection.outlook.com." So, please let your admin check the MX record. Moreover, please check if the SMTP port is 25/TLS.
Upvotes: 1