Configure Email Notifications

Allow RapidDeploy to send emails for the events you want notifying

Emails can be configured to be sent from the RapidDeploy server (‘Server notifications’) and from the deployment job target server (‘Orchestration notifications’).

1. Orchestration notifications

This type of notification can be configured under the ‘Resources’ -> ‘Projects’ -> [PROJECT] -> ‘Orchestration’ -> ‘Settings’ tab. They only notify the success or failure of a Job deployment and do not admit customization using a template. These notification emails are sent from the target server, not from the RapidDeploy server. The parameters to configure are:
  • Enabled: to turn on or off this type of notifications.
  • Notification Email Address: List of email addresses of the person(s) to be notified
  • Email Host (SMTP): hostname of the SMTP server.
  • Email Port (SMTP): port of the SMTP server.
  • Email Sender Address (SMTP Auth): username to authenticate against the SMTP server, also the sender email.
  • Email Credentials (SMTP Auth): password to authentication the SMTP server.

2. Server notifications

This type of notification affects a number of different aspects of the tool including all the notifications regarding the approval workflow process and the different outcomes of a Job deployment. These notifications are sent from the RapidDeploy server and do admit customization. In order for these notifications to work you need to perform two actions:
  • Modify the application properties file ${MV_HOME}/bin/rapiddeploy.properties to configure a proper SMTP server (see below)
  • All users involved in the deployment or approval process must have their email accounts set in their user settings by updating their email address in ‘Menu’ -> ‘User’ -> ‘About Me’.

2.1 Configuration

To configure the SMTP server used to send email notifications to users from the RapidDeploy framework server, edit these settings. Email SMTP settings are set in the  ${MV_HOME}/bin/rapiddeploy.properties file. Please see the section below:
#---------------------------------
# Email settings
#---------------------------------
email.smtp.host=127.0.0.1
email.smtp.port=
email.smtp.username=
email.smtp.password=
email.sender.address=rapiddeploy@midvision.com
email.rd.url=http://localhost:9090/MidVision
  • email.smtp.host : Hostname of the SMTP server (mandatory)
  • email.smtp.port : Port of the SMTP server (optional)
  • email.smtp.username : Username to authenticate sending emails on the SMTP server (optional)
  • email.smtp.password : Password to authenticate sending emails on the SMTP server (optional). This can be a plain text password or an encrypted password using the RapidDeploy encryption tool (use ’email.smtp.password’ as the key when generating the encrypted password).
  • email.sender.address : Email sender address
  • email.rd.url : URL to the RapidDeploy server that sent the email. This is included in the email as a link back in to RapidDeploy.
  • email.user.password : Boolean to define if the users password is emailed to the user on user creation. Defaults to false.

2.2 Customise Email Notification Templates

The Apache Velocity templating engine is used to generate the emails RapidDeploy sends. The templates are stored in the web application classes directory but can be overriden and customised. By default the templates are stored in the rapiddeploy-services.jar file in the web application, in a directory named emailtemplates. These files can be copied to ${MV_HOME} and then the template can be customised. The template files in that directory will override the template files in the application classpath. The location of the templates can be configured by adding the following Email Template settings in the ${MV_HOME}/bin/rapiddeploy.properties file. Details of how to configure these settings can be found on Apache Velocity Web Site: Velocity Developers Guide. Default settings in the ${MV_HOME}/web-apps/tomcat/webapps/MidVision/WEB-INF/classes/rapiddeploy_default.properties
#--------------------------------------------
# Email Template settings
#--------------------------------------------
resource.loader=file, class
#resource.loader=file, class, jar
file.resource.loader.description = Velocity File Resource Loader
file.resource.loader.class = org.apache.velocity.runtime.resource.loader.FileResourceLoader
file.resource.loader.path = ${MV_HOME}/emailtemplates
file.resource.loader.cache = false
file.resource.loader.modificationCheckInterval = 0
class.resource.loader.description = Velocity Classpath Resource Loader
class.resource.loader.class = org.apache.velocity.runtime.resource.loader.ClasspathResourceLoader
jar.resource.loader.description = Velocity Jar  Resource Loader
jar.resource.loader.class = org.apache.velocity.runtime.resource.loader.JarResourceLoader
jar.resource.loader.path = jar:file:/${MV_HOME}/emailtemplates/defaultemailtemplates.jar