@backstage/plugin-notifications-backend-module-email 0.3.4 → 0.3.5-next.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +16 -0
- package/README.md +35 -4
- package/package.json +12 -12
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @backstage/plugin-notifications-backend-module-email
|
|
2
2
|
|
|
3
|
+
## 0.3.5-next.0
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- bed5f35: Added more examples of the plugin configuration
|
|
8
|
+
- Updated dependencies
|
|
9
|
+
- @backstage/backend-plugin-api@1.1.1-next.0
|
|
10
|
+
- @backstage/catalog-client@1.9.0
|
|
11
|
+
- @backstage/catalog-model@1.7.2
|
|
12
|
+
- @backstage/config@1.3.1
|
|
13
|
+
- @backstage/integration-aws-node@0.1.14
|
|
14
|
+
- @backstage/types@1.2.0
|
|
15
|
+
- @backstage/plugin-catalog-node@1.15.1-next.0
|
|
16
|
+
- @backstage/plugin-notifications-common@0.0.7
|
|
17
|
+
- @backstage/plugin-notifications-node@0.2.11-next.0
|
|
18
|
+
|
|
3
19
|
## 0.3.4
|
|
4
20
|
|
|
5
21
|
### Patch Changes
|
package/README.md
CHANGED
|
@@ -24,13 +24,13 @@ export const notificationsModuleEmailDecorator = createBackendModule({
|
|
|
24
24
|
},
|
|
25
25
|
async init({ emailTemplates }) {
|
|
26
26
|
emailTemplates.setTemplateRenderer({
|
|
27
|
-
getSubject(notification) {
|
|
27
|
+
async getSubject(notification) {
|
|
28
28
|
return `New notification from ${notification.source}`;
|
|
29
29
|
},
|
|
30
|
-
getText(notification) {
|
|
30
|
+
async getText(notification) {
|
|
31
31
|
return notification.content;
|
|
32
32
|
},
|
|
33
|
-
getHtml(notification) {
|
|
33
|
+
async getHtml(notification) {
|
|
34
34
|
return `<p>${notification.content}</p>`;
|
|
35
35
|
},
|
|
36
36
|
});
|
|
@@ -54,19 +54,50 @@ notifications:
|
|
|
54
54
|
secure: false
|
|
55
55
|
username: 'my-username'
|
|
56
56
|
password: 'my-password'
|
|
57
|
+
|
|
58
|
+
# AWS SES
|
|
59
|
+
# transportConfig:
|
|
60
|
+
# transport: 'ses'
|
|
61
|
+
# accessKeyId: 'my-access-key
|
|
62
|
+
# region: 'us-west-2'
|
|
63
|
+
|
|
64
|
+
# sendmail
|
|
65
|
+
# transportConfig:
|
|
66
|
+
# transport: 'sendmail'
|
|
67
|
+
# path: '/usr/sbin/sendmail'
|
|
68
|
+
# newline: 'unix'
|
|
69
|
+
|
|
57
70
|
# The email sender address
|
|
58
71
|
sender: 'sender@mycompany.com'
|
|
59
72
|
replyTo: 'no-reply@mycompany.com'
|
|
60
|
-
# Who to
|
|
73
|
+
# Who to send email for broadcast notifications
|
|
61
74
|
broadcastConfig:
|
|
62
75
|
receiver: 'users'
|
|
63
76
|
# How many emails to send concurrently, defaults to 2
|
|
64
77
|
concurrencyLimit: 10
|
|
78
|
+
# How much to throttle between emails, defaults to 100ms
|
|
79
|
+
throttleInterval:
|
|
80
|
+
seconds: 60
|
|
65
81
|
# Cache configuration for email addresses
|
|
66
82
|
# This is to prevent unnecessary calls to the catalog
|
|
67
83
|
cache:
|
|
68
84
|
ttl:
|
|
69
85
|
days: 1
|
|
86
|
+
# Notification filter which this processor will handle
|
|
87
|
+
filter:
|
|
88
|
+
# Minimum severity of the notification to send email
|
|
89
|
+
minSeverity: high
|
|
90
|
+
# Maximum severity of the notification to send email
|
|
91
|
+
maxSeverity: critical
|
|
92
|
+
# Topics that are excluded from sending email
|
|
93
|
+
excludedTopics:
|
|
94
|
+
- scaffolder
|
|
95
|
+
# List of allowed email addresses to get notifications via email
|
|
96
|
+
allowlistEmailAddresses:
|
|
97
|
+
- john.doe@backstage.io
|
|
98
|
+
# List of denied email addresses to get notifications via email
|
|
99
|
+
denylistEmailAddresses:
|
|
100
|
+
- jane.doe@backstage.io
|
|
70
101
|
```
|
|
71
102
|
|
|
72
103
|
See `config.d.ts` for more options for configuration.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage/plugin-notifications-backend-module-email",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.5-next.0",
|
|
4
4
|
"description": "The email backend module for the notifications plugin.",
|
|
5
5
|
"backstage": {
|
|
6
6
|
"role": "backend-plugin-module",
|
|
@@ -36,22 +36,22 @@
|
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"@aws-sdk/client-ses": "^3.550.0",
|
|
38
38
|
"@aws-sdk/types": "^3.347.0",
|
|
39
|
-
"@backstage/backend-plugin-api": "
|
|
40
|
-
"@backstage/catalog-client": "
|
|
41
|
-
"@backstage/catalog-model": "
|
|
42
|
-
"@backstage/config": "
|
|
43
|
-
"@backstage/integration-aws-node": "
|
|
44
|
-
"@backstage/plugin-catalog-node": "
|
|
45
|
-
"@backstage/plugin-notifications-common": "
|
|
46
|
-
"@backstage/plugin-notifications-node": "
|
|
47
|
-
"@backstage/types": "
|
|
39
|
+
"@backstage/backend-plugin-api": "1.1.1-next.0",
|
|
40
|
+
"@backstage/catalog-client": "1.9.0",
|
|
41
|
+
"@backstage/catalog-model": "1.7.2",
|
|
42
|
+
"@backstage/config": "1.3.1",
|
|
43
|
+
"@backstage/integration-aws-node": "0.1.14",
|
|
44
|
+
"@backstage/plugin-catalog-node": "1.15.1-next.0",
|
|
45
|
+
"@backstage/plugin-notifications-common": "0.0.7",
|
|
46
|
+
"@backstage/plugin-notifications-node": "0.2.11-next.0",
|
|
47
|
+
"@backstage/types": "1.2.0",
|
|
48
48
|
"lodash": "^4.17.21",
|
|
49
49
|
"nodemailer": "^6.9.13",
|
|
50
50
|
"p-throttle": "^4.1.1"
|
|
51
51
|
},
|
|
52
52
|
"devDependencies": {
|
|
53
|
-
"@backstage/backend-test-utils": "
|
|
54
|
-
"@backstage/cli": "
|
|
53
|
+
"@backstage/backend-test-utils": "1.2.1-next.0",
|
|
54
|
+
"@backstage/cli": "0.29.5-next.0",
|
|
55
55
|
"@types/nodemailer": "^6.4.14"
|
|
56
56
|
},
|
|
57
57
|
"configSchema": "config.d.ts",
|