Using Gmail as an SMTP host for Sakai

This bit of code has been around for a while, but I’m not sure it’s written up anywhere except in Jira, so here goes, how to setup Sakai to use GMail for sending email:

smtp@org.sakaiproject.email.api.EmailService=smtp.gmail.com
smtpPort@org.sakaiproject.email.api.EmailService=587
smtpUser@org.sakaiproject.email.api.EmailService=<username>
smtpPassword@org.sakaiproject.email.api.EmailService=<password>
smtpUseSSL@org.sakaiproject.email.api.EmailService=true
smtpDebug@org.sakaiproject.email.api.EmailService=true (optional)

And for development, you can’t beat this setting for testing email without it actually being sent:

testMode@org.sakaiproject.email.api.EmailService=true
Advertisements