Skip to main content

Email Notifications - SMTP Configuration

In order to utilize email notifications for job alerts, e.g. job failures, business alerts, Adobe audit alerts, etc. SMTP needs to be configured within the Syntasa installation. Depending on the way the Syntasa platform was installed, one of the two below sets of steps needs to be completed.

Setup on VM deployments

  1. Log into the app server and switch user to SMA:
   AWS:  
ssh -i /keys/syntasa_apps.pem centos@<public-ip>
sudo su - sma

GCP:
gcloud compute --project "project-name" ssh --zone "erope-west1-b" "app-server-40"
sudo su - sma
  1. Use the below commands to update the SMTP details. Replace the parameters appropriately, i.e., id, hostname, port, username, password, from address and recipients:
   curl -X POST \  
http://localhost:8300/services/notification-service/notifications \
-H 'Content-Type: application/json' \
-d '{"id":<11>,"type":"EMAIL","parameters":{"hostname":"<smtp.office365.com>","port":"<587>","password":"<*********>","username":"<test@syntasa.com>","fromAddress":"<test@syntasa.com>","recipients":"<test1@syntasa.com>,<test2@syntasa.com>"}}'

Note : add default recipients to "parameters" -> "recipients" with comma separated list of strings
  1. Use the below command to retrieve existing entries, if any:
   curl -X GET http://localhost:8300/services/notification-service/notifications
  1. Use the below command to delete any unwanted entries:
   curl -X DELETE http://localhost:8300/services/notification-service/notifications/<id>

Setup on Kubernetes deployments

  1. ssh into one of the Kubernetes VM instances:
   AWS:  
ssh -i /keys/syntasa_apps.pem centos@<public-ip>

GCP:
gcloud compute --project "project-name" ssh --zone "erope-west1-b" "gke-instance-name"

Note:
gke-instance-name -> get it from vm instance page.
  1. Run the following docker command:
   docker ps -a | grep syntasa-notification-service  

take the container id

docker exec -it <container id> sh
  1. Use the below commands to update the SMTP details. Replace the parameters appropriately, i.e., id, hostname, port, username, password, from address and recipients:
   apk add curl && curl -X POST \  
http://localhost:8300/services/notification-service/notifications \
-H 'Content-Type: application/json' \
-d '{"id":<11>,"type":"EMAIL","parameters":{"hostname":"<smtp.office365.com>","port":"<587>","password":"<*********>","username":"<test@syntasa.com>","fromAddress":"<test@syntasa.com>","recipients":"<test1@syntasa.com>,<test2@syntasa.com>"}}'
  1. Use the below command to retrieve if there are any entries:
   curl -X GET http://localhost:8300/services/notification-service/notifications
  1. Use the below command to delete if any unwanted entries:
   curl -X DELETE http://localhost:8300/services/notification-service/notifications/<id>