Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Email Templates #15

Open
wants to merge 2 commits into
base: soracom_main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions emails/templates/layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@
<table class="twelve columns">
<tr>
<td class="twelve sub-columns center">
<img class="logo" src="https://grafana.com/assets/img/logo_new_transparent_200x48.png" style="width: 200px; float: none; display: inline">
<img class="logo" src="https://assets.soracom.io/brand/logo/assets/soracom-logo-white.svg?fm=png&w=400" style="width: 200px; float: none; display: inline">
</td>
<td class="expander"></td>
</tr>
Expand Down Expand Up @@ -142,8 +142,8 @@
<td class="twelve" align="center">
<center>
<p style="text-align: center; font-size: 12px; color: #999999;">
Sent by <a href="[[.AppUrl]]">Grafana v[[.BuildVersion]]</a>
<br />&copy; 2022 Grafana Labs
Sent by <a href="[[.AppUrl]]">SORACOM Lagoon</a>
<br />
</p>
</center>
</td>
Expand Down
2 changes: 1 addition & 1 deletion emails/templates/reset_password.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[[Subject .Subject "Reset your Grafana password - [[.Name]]"]]
[[Subject .Subject "Reset your Lagoon password - [[.Name]]"]]

<table class="row">
<tr>
Expand Down
2 changes: 1 addition & 1 deletion emails/templates/reset_password.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[[Subject .Subject "Reset your Grafana password - [[.Name]]"]]
[[Subject .Subject "Reset your Lagoon password - [[.Name]]"]]

Hi [[.Name]],

Expand Down
2 changes: 1 addition & 1 deletion pkg/services/notifications/notifications_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ func TestSendEmailAsync(t *testing.T) {
sentMsg := <-sut.mailQueue
assert.Contains(t, sentMsg.Body["text/html"], "body")
assert.NotContains(t, sentMsg.Body["text/plain"], "body")
assert.Equal(t, "Reset your Grafana password - [email protected]", sentMsg.Subject)
assert.Equal(t, "Reset your Lagoon password - [email protected]", sentMsg.Subject)
assert.NotContains(t, sentMsg.Body["text/html"], "Subject")
assert.NotContains(t, sentMsg.Body["text/plain"], "Subject")

Expand Down
6 changes: 3 additions & 3 deletions public/emails/alert_notification.html
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@
<table class="twelve columns" style="border-spacing: 0; border-collapse: collapse; vertical-align: top; text-align: left; width: 580px; margin: 0 auto; padding: 0;">
<tr style="vertical-align: top; padding: 0;" align="left">
<td class="twelve sub-columns center" style="word-break: break-word; -webkit-hyphens: auto; -moz-hyphens: auto; hyphens: auto; border-collapse: collapse !important; min-width: 0px; width: 100%; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; font-size: 14px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0; padding: 0px 10px 10px 0px;" align="center" valign="top">
<img class="logo" src="https://grafana.com/assets/img/logo_new_transparent_200x48.png" style="width: 200px; display: inline; outline: none !important; text-decoration: none !important; -ms-interpolation-mode: bicubic; clear: both; border-width: 0;" align="none" />
<img class="logo" src="https://assets.soracom.io/brand/logo/assets/soracom-logo-white.svg?fm=png&w=400" style="width: 200px; display: inline; outline: none !important; text-decoration: none !important; -ms-interpolation-mode: bicubic; clear: both; border-width: 0;" align="none" />
</td>
<td class="expander" style="word-break: break-word; -webkit-hyphens: auto; -moz-hyphens: auto; hyphens: auto; border-collapse: collapse !important; visibility: hidden; width: 0px; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; font-size: 14px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0; padding: 0;" align="left" valign="top"></td>
</tr>
Expand Down Expand Up @@ -352,8 +352,8 @@ <h5 class="data" style="color: #222222; font-family: 'Open Sans', 'Helvetica Neu
<td class="twelve" align="center" style="word-break: break-word; -webkit-hyphens: auto; -moz-hyphens: auto; hyphens: auto; border-collapse: collapse !important; width: 100%; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; font-size: 14px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0; padding: 0px 0px 10px;" valign="top">
<center style="width: 100%; min-width: 580px;">
<p style="font-size: 12px; color: #999999; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0 0 10px; padding: 0;" align="center">
Sent by <a href="{{.AppUrl}}" style="color: #E67612; text-decoration: none;">Grafana v{{.BuildVersion}}</a>
<br />© 2022 Grafana Labs
Sent by <a href="{{.AppUrl}}" style="color: #E67612; text-decoration: none;">SORACOM Lagoon</a>
<br />
</p>
</center>
</td>
Expand Down
2 changes: 1 addition & 1 deletion public/emails/alert_notification.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ View your Alert rule:
Go to the Alerts page:
{{.AlertPageUrl}}

Sent by Grafana v{{.BuildVersion}} (c) 2022 Grafana Labs
Sent by SORACOM Lagoon
4 changes: 2 additions & 2 deletions public/emails/alert_notification_example.html
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@
<table class="twelve columns" style="border-collapse: collapse; border-spacing: 0; margin: 0 auto; padding: 0; text-align: left; vertical-align: top; width: 580px;">
<tr style="padding: 0; vertical-align: top;" align="left">
<td class="six sub-columns center" style="-moz-hyphens: auto; -webkit-font-smoothing: antialiased; -webkit-hyphens: auto; -webkit-text-size-adjust: none; border-collapse: collapse !important; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-size: 14px; font-weight: normal; hyphens: auto; line-height: 19px; margin: 0; min-width: 0px; padding: 0px 10px 10px 0px; width: 50%; word-break: break-word;" align="center" valign="top">
<img class="logo" src="https://grafana.com/assets/img/logo_new_transparent_200x48.png" style="-ms-interpolation-mode: bicubic; border: 0; clear: both; display: inline; outline: none !important; text-decoration: none !important; width: 200px;" align="none" />
<img class="logo" src="https://assets.soracom.io/brand/logo/assets/soracom-logo-white.svg?fm=png&w=400" style="-ms-interpolation-mode: bicubic; border: 0; clear: both; display: inline; outline: none !important; text-decoration: none !important; width: 200px;" align="none" />
</td>
<td class="expander" style="-moz-hyphens: auto; -webkit-font-smoothing: antialiased; -webkit-hyphens: auto; -webkit-text-size-adjust: none; border-collapse: collapse !important; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-size: 14px; font-weight: normal; hyphens: auto; line-height: 19px; margin: 0; padding: 0; visibility: hidden; width: 0px; word-break: break-word;" align="left" valign="top"></td>
</tr>
Expand Down Expand Up @@ -340,7 +340,7 @@ <h3 style="-webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none;
<td class="twelve" align="center" style="-moz-hyphens: auto; -webkit-font-smoothing: antialiased; -webkit-hyphens: auto; -webkit-text-size-adjust: none; border-collapse: collapse !important; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-size: 14px; font-weight: normal; hyphens: auto; line-height: 19px; margin: 0; padding: 0px 0px 10px; width: 100%; word-break: break-word;" valign="top">
<center style="min-width: 580px; width: 100%;">
<p style="-webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; color: #999999; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-size: 12px; font-weight: normal; line-height: 19px; margin: 0 0 10px; padding: 0;" align="center">
Sent by <a href="{{.AppUrl}}" style="color: #E67612; text-decoration: none;">Grafana v{{.BuildVersion}}</a>
Sent by <a href="{{.AppUrl}}" style="color: #E67612; text-decoration: none;">SORACOM Lagoon</a>
<br />© 2016 Grafana and raintank
</p>
</center>
Expand Down
6 changes: 3 additions & 3 deletions public/emails/invited_to_org.html
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@
<table class="twelve columns" style="border-spacing: 0; border-collapse: collapse; vertical-align: top; text-align: left; width: 580px; margin: 0 auto; padding: 0;">
<tr style="vertical-align: top; padding: 0;" align="left">
<td class="twelve sub-columns center" style="word-break: break-word; -webkit-hyphens: auto; -moz-hyphens: auto; hyphens: auto; border-collapse: collapse !important; min-width: 0px; width: 100%; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; font-size: 14px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0; padding: 0px 10px 10px 0px;" align="center" valign="top">
<img class="logo" src="https://grafana.com/assets/img/logo_new_transparent_200x48.png" style="width: 200px; display: inline; outline: none !important; text-decoration: none !important; -ms-interpolation-mode: bicubic; clear: both; border-width: 0;" align="none" />
<img class="logo" src="https://assets.soracom.io/brand/logo/assets/soracom-logo-white.svg?fm=png&w=400" style="width: 200px; display: inline; outline: none !important; text-decoration: none !important; -ms-interpolation-mode: bicubic; clear: both; border-width: 0;" align="none" />
</td>
<td class="expander" style="word-break: break-word; -webkit-hyphens: auto; -moz-hyphens: auto; hyphens: auto; border-collapse: collapse !important; visibility: hidden; width: 0px; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; font-size: 14px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0; padding: 0;" align="left" valign="top"></td>
</tr>
Expand Down Expand Up @@ -265,8 +265,8 @@ <h4 class="center" style="color: #222222; font-family: 'Open Sans', 'Helvetica N
<td class="twelve" align="center" style="word-break: break-word; -webkit-hyphens: auto; -moz-hyphens: auto; hyphens: auto; border-collapse: collapse !important; width: 100%; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; font-size: 14px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0; padding: 0px 0px 10px;" valign="top">
<center style="width: 100%; min-width: 580px;">
<p style="font-size: 12px; color: #999999; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0 0 10px; padding: 0;" align="center">
Sent by <a href="{{.AppUrl}}" style="color: #E67612; text-decoration: none;">Grafana v{{.BuildVersion}}</a>
<br />© 2022 Grafana Labs
Sent by <a href="{{.AppUrl}}" style="color: #E67612; text-decoration: none;">SORACOM Lagoon</a>
<br />
</p>
</center>
</td>
Expand Down
2 changes: 1 addition & 1 deletion public/emails/invited_to_org.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ below your username.
Log in now:
{{.AppUrl}}

Sent by Grafana v{{.BuildVersion}} (c) 2022 Grafana Labs
Sent by SORACOM Lagoon
6 changes: 3 additions & 3 deletions public/emails/new_user_invite.html
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@
<table class="twelve columns" style="border-spacing: 0; border-collapse: collapse; vertical-align: top; text-align: left; width: 580px; margin: 0 auto; padding: 0;">
<tr style="vertical-align: top; padding: 0;" align="left">
<td class="twelve sub-columns center" style="word-break: break-word; -webkit-hyphens: auto; -moz-hyphens: auto; hyphens: auto; border-collapse: collapse !important; min-width: 0px; width: 100%; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; font-size: 14px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0; padding: 0px 10px 10px 0px;" align="center" valign="top">
<img class="logo" src="https://grafana.com/assets/img/logo_new_transparent_200x48.png" style="width: 200px; display: inline; outline: none !important; text-decoration: none !important; -ms-interpolation-mode: bicubic; clear: both; border-width: 0;" align="none" />
<img class="logo" src="https://assets.soracom.io/brand/logo/assets/soracom-logo-white.svg?fm=png&w=400" style="width: 200px; display: inline; outline: none !important; text-decoration: none !important; -ms-interpolation-mode: bicubic; clear: both; border-width: 0;" align="none" />
</td>
<td class="expander" style="word-break: break-word; -webkit-hyphens: auto; -moz-hyphens: auto; hyphens: auto; border-collapse: collapse !important; visibility: hidden; width: 0px; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; font-size: 14px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0; padding: 0;" align="left" valign="top"></td>
</tr>
Expand Down Expand Up @@ -267,8 +267,8 @@ <h4 class="center" style="color: #222222; font-family: 'Open Sans', 'Helvetica N
<td class="twelve" align="center" style="word-break: break-word; -webkit-hyphens: auto; -moz-hyphens: auto; hyphens: auto; border-collapse: collapse !important; width: 100%; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; font-size: 14px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0; padding: 0px 0px 10px;" valign="top">
<center style="width: 100%; min-width: 580px;">
<p style="font-size: 12px; color: #999999; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0 0 10px; padding: 0;" align="center">
Sent by <a href="{{.AppUrl}}" style="color: #E67612; text-decoration: none;">Grafana v{{.BuildVersion}}</a>
<br />© 2022 Grafana Labs
Sent by <a href="{{.AppUrl}}" style="color: #E67612; text-decoration: none;">SORACOM Lagoon</a>
<br />
</p>
</center>
</td>
Expand Down
2 changes: 1 addition & 1 deletion public/emails/new_user_invite.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ directly:

{{.LinkUrl}}

Sent by Grafana v{{.BuildVersion}} (c) 2022 Grafana Labs
Sent by SORACOM Lagoon
6 changes: 3 additions & 3 deletions public/emails/ng_alert_notification.html
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@
<table class="twelve columns" style="border-spacing: 0; border-collapse: collapse; vertical-align: top; text-align: left; width: 580px; margin: 0 auto; padding: 0;">
<tr style="vertical-align: top; padding: 0;" align="left">
<td class="twelve sub-columns center" style="word-break: break-word; -webkit-hyphens: auto; -moz-hyphens: auto; hyphens: auto; border-collapse: collapse !important; min-width: 0px; width: 100%; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; font-size: 14px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0; padding: 0px 10px 10px 0px;" align="center" valign="top">
<img class="logo" src="https://grafana.com/assets/img/logo_new_transparent_200x48.png" style="width: 200px; display: inline; outline: none !important; text-decoration: none !important; -ms-interpolation-mode: bicubic; clear: both; border-width: 0;" align="none" />
<img class="logo" src="https://assets.soracom.io/brand/logo/assets/soracom-logo-white.svg?fm=png&w=400" style="width: 200px; display: inline; outline: none !important; text-decoration: none !important; -ms-interpolation-mode: bicubic; clear: both; border-width: 0;" align="none" />
</td>
<td class="expander" style="word-break: break-word; -webkit-hyphens: auto; -moz-hyphens: auto; hyphens: auto; border-collapse: collapse !important; visibility: hidden; width: 0px; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; font-size: 14px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0; padding: 0;" align="left" valign="top"></td>
</tr>
Expand Down Expand Up @@ -367,8 +367,8 @@
<td class="twelve" align="center" style="word-break: break-word; -webkit-hyphens: auto; -moz-hyphens: auto; hyphens: auto; border-collapse: collapse !important; width: 100%; color: #222222; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; font-size: 14px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0; padding: 0px 0px 10px;" valign="top">
<center style="width: 100%; min-width: 580px;">
<p style="font-size: 12px; color: #999999; font-family: 'Open Sans', 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif; font-weight: normal; line-height: 19px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none; margin: 0 0 10px; padding: 0;" align="center">
Sent by <a href="{{.AppUrl}}" style="color: #E67612; text-decoration: none;">Grafana v{{.BuildVersion}}</a>
<br />© 2022 Grafana Labs
Sent by <a href="{{.AppUrl}}" style="color: #E67612; text-decoration: none;">SORACOM Lagoon</a>
<br />
</p>
</center>
</td>
Expand Down
2 changes: 1 addition & 1 deletion public/emails/ng_alert_notification.txt
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,4 @@ Annotations:
Go to the Alerts page:
{{.AlertPageUrl}}

Sent by Grafana v{{.BuildVersion}} (c) 2022 Grafana Labs
Sent by SORACOM Lagoon
Loading