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

[Web] Add access list notification type #51426

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

rudream
Copy link
Contributor

@rudream rudream commented Jan 23, 2025

Purpose

e counterpart: https://github.com/gravitational/teleport.e/pull/5922

Adds a new notification type for access list reminder notifications. The logic that creates these notifications will be in a separate PR.

Demo

image

@rudream rudream added no-changelog Indicates that a PR does not require a changelog entry backport/branch/v17 labels Jan 23, 2025
@rudream rudream requested review from avatus and removed request for flyinghermit January 23, 2025 18:29
@rudream rudream force-pushed the yassine/access-list-notification-type branch from 3e92962 to e9bc87e Compare January 23, 2025 20:11
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i kinda wish you included the logic that will use these, b/c to me NotificationAccessListReviewXXX and NotificationIdentifierPrefixAccessListXXX both look unique to me? or i guess i dont understand the use for NotificationIdentifierPrefixAccessListXXX?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The prefix isn't a notification subkind, it's just the prefix for the "unique notification identifier" resource which will be mapped to these notifications to prevent duplicates.

For more context see this PR: #51358

Comment on lines +310 to +313
case *notificationsv1.GlobalNotificationSpec_ByUsers:
userList := matcher.ByUsers.GetUsers()
return slices.Contains(userList, authCtx.User.GetName())

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is there a test for this? or exclude this change?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport/branch/v17 no-changelog Indicates that a PR does not require a changelog entry size/md ui
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants