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

220 - Blocking resources #258

Merged
merged 30 commits into from
Apr 21, 2024
Merged

220 - Blocking resources #258

merged 30 commits into from
Apr 21, 2024

Conversation

lm-sec
Copy link
Collaborator

@lm-sec lm-sec commented Mar 21, 2024

Missing:

  • Some e2e tests for authorizations
  • Unit tests for
    • Susbcription triggers - a blocked resource should not trigger
    • Cron subscriptions - a blocked resource should not launch a job
  • I want to mention the blocking of resources in the documentation

I went for a pretty good upgrade of the documentation 📜

Closes #220

Now possible to block a resource so that it is not used in any subscription, cron or event. It allows for remembering a resource, but not scanning/probing them again.

The PR introduces the "is" filter for resources, where you can specify a boolean. The only supported boolean right now is "blocked. "is: blocked" represents true, "-is: blocked" represents false.

The UI, when blocking a resource, will always confirm with the user that they really want to block/unblock a resource.

I chose to not delete the data of a resource when blocked. It makes more sense to remember what they had, for future reference and for unblocking.

The UI for the 3 types of resources is similar, and only the host's UI will be shown.

By default, the page is filtered by "-is: blocked" to only show items that are not blocked.
image

You can block in the list resources page:
image

You can block in the view-resource page:
image

A blocked resource shows that it is blocked by adding the panel section "Blocked" with the timestamp.
image

@lm-sec lm-sec added this to the Stalker 0.1.0 Beta milestone Mar 21, 2024
@lm-sec lm-sec requested a review from Aboisier March 21, 2024 04:41
@lm-sec lm-sec self-assigned this Mar 21, 2024
@lm-sec lm-sec linked an issue Mar 24, 2024 that may be closed by this pull request
Base automatically changed from prod_tweaks_and_dependency_install to main March 25, 2024 12:28
Copy link
Collaborator

@Aboisier Aboisier left a comment

Choose a reason for hiding this comment

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

Petites suggestions, mais LGTM! 🎉

@lm-sec lm-sec merged commit e70654d into main Apr 21, 2024
6 checks passed
@lm-sec lm-sec deleted the 220-blocking_resources-2 branch April 21, 2024 01:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

As a user, I want to block a resource and never hear about it again
2 participants