Created
September 16, 2019 17:18
-
-
Save jhonatasfender/a2d474c37579f021af8ec06130977740 to your computer and use it in GitHub Desktop.
spring boot gmail email setup that worked
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
spring.mail.host=smtp.gmail.com | |
spring.mail.port=465 | |
[email protected] | |
spring.mail.password=xxxx xxxx xxxx xxxx | |
# Other properties | |
spring.mail.properties.mail.smtp.auth=true | |
spring.mail.properties.mail.smtp.connectiontimeout=5000 | |
spring.mail.properties.mail.smtp.timeout=5000 | |
spring.mail.properties.mail.smtp.writetimeout=5000 | |
# TLS , port 587 | |
#spring.mail.properties.mail.smtp.starttls.enable=true | |
# SSL, post 465 | |
spring.mail.properties.mail.smtp.socketFactory.port = 465 | |
spring.mail.properties.mail.smtp.socketFactory.class = javax.net.ssl.SSLSocketFactory | |
# https://www.mkyong.com/java/javamail-api-sending-email-via-gmail-smtp-example/ | |
# https://www.mkyong.com/spring-boot/spring-boot-how-to-send-email-via-smtp/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment