fix subject of the emails
This commit is contained in:
@@ -190,7 +190,7 @@ function appUp(mailTo, app) {
|
||||
var mailOptions = {
|
||||
from: mailConfig.notificationFrom,
|
||||
to: mailTo,
|
||||
subject: util.format('[%s] App %s is back online', mailConfig.cloudronName, app.fqdn),
|
||||
subject: `[${mailConfig.cloudronName}] App ${app.fqdn} is back online`,
|
||||
text: render('app_up.ejs', { title: app.manifest.title, appFqdn: app.fqdn, format: 'text' })
|
||||
};
|
||||
|
||||
@@ -210,7 +210,7 @@ function appDied(mailTo, app) {
|
||||
var mailOptions = {
|
||||
from: mailConfig.notificationFrom,
|
||||
to: mailTo,
|
||||
subject: util.format('[%s] App %s is down', mailConfig.cloudronName, app.fqdn),
|
||||
subject: `[${mailConfig.cloudronName}] App ${app.fqdn} is down`,
|
||||
text: render('app_down.ejs', { title: app.manifest.title, appFqdn: app.fqdn, supportEmail: mailConfig.supportEmail, format: 'text' })
|
||||
};
|
||||
|
||||
@@ -285,7 +285,7 @@ function boxUpdateAvailable(mailTo, updateInfo, callback) {
|
||||
var mailOptions = {
|
||||
from: mailConfig.notificationFrom,
|
||||
to: mailTo,
|
||||
subject: 'Cloudron update available',
|
||||
subject: `[${mailConfig.cloudronName}] Cloudron update available`,
|
||||
text: render('box_update_available.ejs', templateDataText),
|
||||
html: render('box_update_available.ejs', templateDataHTML)
|
||||
};
|
||||
@@ -323,7 +323,7 @@ function appUpdatesAvailable(mailTo, apps, callback) {
|
||||
var mailOptions = {
|
||||
from: mailConfig.notificationFrom,
|
||||
to: mailTo,
|
||||
subject: 'App updates available',
|
||||
subject: `[${mailConfig.cloudronName}] App update available`,
|
||||
text: render('app_updates_available.ejs', templateDataText),
|
||||
html: render('app_updates_available.ejs', templateDataHTML)
|
||||
};
|
||||
@@ -341,7 +341,7 @@ function backupFailed(mailTo, errorMessage, logUrl) {
|
||||
var mailOptions = {
|
||||
from: mailConfig.notificationFrom,
|
||||
to: mailTo,
|
||||
subject: util.format('[%s] Failed to backup', mailConfig.cloudronName),
|
||||
subject: `[${mailConfig.cloudronName}] Failed to backup`,
|
||||
text: render('backup_failed.ejs', { cloudronName: mailConfig.cloudronName, message: errorMessage, logUrl: logUrl, format: 'text' })
|
||||
};
|
||||
|
||||
@@ -360,7 +360,7 @@ function certificateRenewalError(mailTo, domain, message) {
|
||||
var mailOptions = {
|
||||
from: mailConfig.notificationFrom,
|
||||
to: mailTo,
|
||||
subject: util.format('[%s] Certificate renewal error', domain),
|
||||
subject: `[${mailConfig.cloudronName}] Certificate renewal error`,
|
||||
text: render('certificate_renewal_error.ejs', { domain: domain, message: message, format: 'text' })
|
||||
};
|
||||
|
||||
@@ -378,7 +378,7 @@ function boxUpdateError(mailTo, message) {
|
||||
var mailOptions = {
|
||||
from: mailConfig.notificationFrom,
|
||||
to: mailTo,
|
||||
subject: util.format('[%s] Cloudron update error', mailConfig.cloudronName),
|
||||
subject: `[${mailConfig.cloudronName}] Cloudron update error`,
|
||||
text: render('box_update_error.ejs', { message: message, format: 'text' })
|
||||
};
|
||||
|
||||
@@ -397,7 +397,7 @@ function oomEvent(mailTo, program, event) {
|
||||
var mailOptions = {
|
||||
from: mailConfig.notificationFrom,
|
||||
to: mailTo,
|
||||
subject: util.format('[%s] %s was restarted (OOM)', mailConfig.cloudronName, program),
|
||||
subject: `[${mailConfig.cloudronName}] ${program} was restarted (OOM)`,
|
||||
text: render('oom_event.ejs', { cloudronName: mailConfig.cloudronName, program: program, event: JSON.stringify(event), format: 'text' })
|
||||
};
|
||||
|
||||
@@ -417,7 +417,7 @@ function sendTestMail(domain, email, callback) {
|
||||
authUser: `no-reply@${domain}`,
|
||||
from: `"${mailConfig.cloudronName}" <no-reply@${domain}>`,
|
||||
to: email,
|
||||
subject: util.format('Test Email from %s', mailConfig.cloudronName),
|
||||
subject: `[${mailConfig.cloudronName}] Test Email`,
|
||||
text: render('test.ejs', { cloudronName: mailConfig.cloudronName, format: 'text'})
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user