AnsweredAssumed Answered

No email functionality

Question asked by fromano on Oct 16, 2015
Latest reply on Oct 22, 2015 by fromano
Hi,

Am running Alfresco Community 5.0.d and am executing a rule that emails a recipient when new content is added to a folder.  I have tried Perform Action: Send Email from the list of Rule Actions, as well as this script:

function sendMail()
{
  var mail = actions.create("mail");
  mail.parameters.to = clenig@bomarko.com["cm:email"];
  mail.parameters.subject = "Supplier Assessment Alert";
  mail.parameters.from = "Docmanagementsystem@gmail.com";
  mail.parameters.template = companyHome.childByNamePath("Data Dictionary/Email Templates/assessment_notification_email.html.ftl");
  mail.parameters.text = "A new Supplier Assessment (BO-13) form has been submitted.";
}

  // execute action against a document
  mail.execute(document);
}
sendMail();

My alfresco-global.properties file has these parameters:

mail.host=smtp.gmail.com
mail.port=465
mail.username=Docmanagementsystem@gmail.com   
mail.password=B0m@rk0
mail.protocol=smtps
mail.smtps.starttls.enable=true
mail.smtps.auth=true
mail.smtp.debug=false
mail.smtp.timeout=30000
mail.from.default=Docmanagementsystem@gmail.com

No one receives any email when I upload a file using Perform Action: Send Email.  Even if I create a site and invite a user, the invite appears as a task on their dashboard - no email generated. 

When new content is uploaded to the folder and I use the javascript above, I get the error (Failure: Failed to execute script 'workspace://SpacesStore/9910b10a-33cc-42d4-a142-08c9efaad4ee': syntax error (workspace://SpacesStore/9910b10a-33cc-42d4-a142-08c9efaad4ee#13)) and the upload is cancelled.

Using the command prompt and mail -s "Text" clenig@bomarko.com <messagefile.txt, I am able to send an email from the computer which is hosting Alfresco.

Can anyone please offer insight into why my Alfresco is not creating emails?

Thank you in advance,
Frank

Outcomes