Add feature toggle for security policies policy scope
What does this MR do and why?
This MR adds a new toggle to enable/disable the Security Policies Policy Scope experimental setting as a group level setting using the cascading settings framework.
We want to release this feature as an experiment.
The toggle itself is behind the security_policies_policy_scope
feature flag, before this toggle is visible to users the feature flag needs to be enabled.
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
Before | After |
---|---|
How to set up and validate locally
- Enable
security_policies_policy_scope
feature flag - Create new root Group
- In Settings -> General -> Permissions and group features find toggle added in this MR
- Create new Compliance Framework
- Create new Project in that group and assign created Compliance Framework to this project and select second project without framework selected
- Create new Scan Execution Policy for the Group and select Policy Scope to be applied only when project has Compliance Framework (ie. add Container Scanning scan for all branches)
- Try to save policy - this should work without any problems
- Run pipeline in both created projects and if scans is properly enforced
- Disable the toggle in Group Setting and run pipelines again; now no scans should be enforced from Scan Execution Policy
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.
Addresses #435501 (closed)
Edited by Alan (Maciej) Paruszewski