forked from RedHatInsights/notifications-backend
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
RHCLOUD-29294 Setup emails for RBAC request-access event type (RedHat…
…Insights#2329) * RHCLOUD-29294 Setup emails for RBAC request-access event type * Updated tests to include request-access - Updated email template to use "action" instead of "data"
- Loading branch information
Showing
7 changed files
with
79 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
engine/src/main/resources/templates/Rbac/requestAccessEmailBodyV2.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
{@boolean renderSection1=true} | ||
{@boolean renderButtonSection1=true} | ||
{#include Common/insightsEmailBody} | ||
{#content-title} | ||
User Access - Console | ||
{/content-title} | ||
{#content-title-section1} | ||
Request for access received | ||
{/content-title-section1} | ||
{#content-body-section1} | ||
<p> | ||
This message is to inform you that a user within your organization has requested access to a page or feature | ||
within console.redhat.com. Please review this request and decide whether to grant or deny access. | ||
</p> | ||
<p> | ||
<strong>User's Request:</strong> | ||
<ul> | ||
<li><strong>URL Path:</strong> {action.events[0].payload.url_path}</li> | ||
<li><strong>Username:</strong> {action.events[0].payload.username}</li> | ||
<li><strong>Email Address:</strong> {action.events[0].payload.user.email}</li> | ||
<li><strong>Message from User:</strong> "{action.events[0].payload.user.request}"</li> | ||
</ul> | ||
<br/> | ||
<strong>Action Required:</strong> | ||
<ul> | ||
<li><strong>Granting Access:</strong>If you decide to grant access, please log in to the console and add the user to the appropriate <a target="blank" href="{environment.url}/iam/user-access/groups/">User Access Group(s).</a></li> | ||
<li><strong>Denying Access:</strong> If you choose to deny access, kindly reach out to the user directly to explain the reason for the denial.</li> | ||
</ul> | ||
</p> | ||
{/content-body-section1} | ||
{#content-button-section1} | ||
<a target="_blank" href="{environment.url}/iam/user-access/groups/}">Review your user access groups in the console</a> | ||
{/content-button-section1} | ||
{/include} |
1 change: 1 addition & 0 deletions
1
engine/src/main/resources/templates/Rbac/requestAccessEmailTitleV2.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Instant notification - Request access - User Access - Console |
1 change: 1 addition & 0 deletions
1
engine/src/main/resources/templates/drawer/Rbac/requestAccess.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<b>{data.events[0].payload.username}</b> has requested access to <b>{data.events[0].payload.url_path}</b>. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters