exception - play activator - runtimeException: smtp.host needs to be set in application.conf in order to use this plugin (or set smtp.mock to true) -


i trying run play activator template named "playstartapp". but, giving me following runtime exception:

runtimeexception: smtp.host needs set in application.conf in order use plugin (or set smtp.mock true)\      java.lang.runtimeexception: smtp.host needs set in application.conf in order use plugin (or set smtp.mock true)          com.typesafe.plugin.commonsmailerplugin$$anonfun$4.apply(mailerplugin.scala:329)          com.typesafe.plugin.commonsmailerplugin$$anonfun$4.apply(mailerplugin.scala:329)          scala.option.getorelse(option.scala:120)          com.typesafe.plugin.commonsmailerplugin.mailerinstance$lzycompute(mailerplugin.scala:329)          com.typesafe.plugin.commonsmailerplugin.mailerinstance(mailerplugin.scala:326)          com.typesafe.plugin.commonsmailerplugin.onstart(mailerplugin.scala:343)          play.api.play$$anonfun$start$1$$anonfun$apply$mcv$sp$1.apply(play.scala:91)`   tried both: - set mail.smtp=mock  - mail.smtp.host=smtp.gmail.com mail.smtp.user=yourgmaillogin mail.smtp.pass=yourgmailpassword mail.smtp.channel=ssl  pls suggest how resolve this? 

in "playstartapp" activator template, can either -

  1. use mock mailer, entering following in conf/application.conf

    smtp.mock=true 

the mock option render email output console. if using activator ui, you'll able see mail output in logs on "run" tab.

  1. mention smtp server details in conf/application.conf

    smtp.host=smtp.gmail.com smtp.port=587 smtp.user="user@gmail.com" smtp.password="password" smtp.ssl=true mail.from="playstartapp@yourdomain.com" mail.sign=the playstartapp team 

you can use gmail servers sending mails well, have mentioned above.

alternatively, in "playstartapp", rename conf/mail.conf.example conf/mail.conf , move smtp related configuration here. please note conf/mail.conf mentioned in .gitignore.

resources (play documentation):

mail configuration parameters

smtp configuratoin


Comments

Popular posts from this blog

javascript - how to protect a flash video from refresh? -

android - Associate same looper with different threads -

visual studio 2010 - Connect to informix database windows form application -