diff --git a/src/commands/monitor.ts b/src/commands/monitor.ts index 5cf78bc..22e3ce5 100644 --- a/src/commands/monitor.ts +++ b/src/commands/monitor.ts @@ -63,15 +63,15 @@ export default class Monitor extends Command { bindBroker(flags['broker-api-url'], flags['broker-token']); bindNotification( { - host: notificationSmtpHost, - port: notificationSmtpPort, - secure: notificationSmtpSecure, + host: flags['notification-smtp-host'], + port: flags['notification-smtp-port'], + secure: flags['notification-smtp-secure'], }, { - from: notificationOptionFrom, - subject: notificationOptionSubject, - text: notificationOptionTemplateText, - html: notificationOptionTemplateHtml, + from: flags['notification-option-from'], + subject: flags['notification-option-subject'], + text: flags['notification-option-template-text'], + html: flags['notification-option-template-html'], }, ); await bindTarget( diff --git a/src/flags.ts b/src/flags.ts index d696183..c987dd7 100644 --- a/src/flags.ts +++ b/src/flags.ts @@ -123,20 +123,22 @@ This service uses your connections in Broker's graph to enable (and disable) acc export const notificationOptionTemplateHtml = { 'notification-option-template-html': Flags.string({ - default: `Hi <%= summary.user.name %>, + default: `
Hi <%= summary.user.name %>,
-This report shows changes to your account access to <%= config.name %>. The following account changes have occurred. +This report shows changes to your account access to <%= config.name %>. The following account changes have occurred.
<% summary.addRoles.forEach(function(role) { %> -Add: <%= role %><% if (addRoleMap[role]) { %> +Add: <%= role %>
<% if (addRoleMap[role]) { %> <%= addRoleMap[role] %> <% }}); %> <% summary.delRoles.forEach(function(role) { %> -Remove: <%= role %> +Remove: <%= role %>
<% }); %> -This service uses your connections in Broker's graph to enable (and disable) access by altering your roles in Common Hosted Single Sign-On (CSS).`, +This service uses your connections in Broker's graph to enable (and disable) access by altering your roles in Common Hosted Single Sign-On (CSS).
+ +`, description: 'The notification template in html', env: 'NOTIFICATION_OPTION_TEMPLATE_HTML', }),