Add namespaces exclusion form
What does this MR do and why?
It adds namespace exclusion form to the namespace limits page, allowing to exclude a namespace from namespace limits/enforcement by selecting a namespace and adding a reason why it has been excluded.
Note: this MR depends on !119537 (merged) and !119737 (merged) being merged first.
Screenshots or screen recordings
before | after |
---|---|
How to set up and validate locally
-
In
bin/rails console
run:Feature.enable(:namespace_limits_admin_dashboard) ::Gitlab::CurrentSettings.update(check_namespace_plan: true)
-
Simulate saas and restart your gdk
$ export GITLAB_SIMULATE_SAAS=1 $ gdk restart
-
Visit
/admin/namespace_limits
as root -
Open devtools to "network" tab
-
In the form at the end of the page, select a namespace and type a reason for exclusion then submit
-
The table should change into busy state and the request should return 200
-
Try selecting the same namespace and fill the reason field and submit, you should see "400 Bad request - already excluded" error
-
Try clearing out the form and submit empty fields, you should see "You must select a namespace and add a reason for excluding it" error
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #381681