Disable license scanning for warn mode

What does this MR do and why?

Disable license scanning for warn mode

  • license scanning will not be enabled for warn mode initially due to technical constraints
  • remove it from the dropdown when warn mode is selected
  • update the banner to mention this
  • disable warn mode selection if license scanning is already selected

EE: true

References

Screenshots or screen recordings

Scenario Screenshot
Warn mode selected - remove license scanning from dropdown Screenshot_2025-09-28_at_9.41.32_PM
License scanning selected - disable warn mode Screenshot_2025-09-28_at_9.41.23_PM
Disabled rule mode if incorrect syntax created in yaml mode Screenshot_2025-09-29_at_11.54.40_AM

How to set up and validate locally

  1. Upload a GitLab Ultimate license
  2. Enable the security_policy_approval_warn_mode feature flag (http://gdk.test:3000/rails/features)
  3. Navigate to a project/group => Secure => Policies => New policy => Merge Request Approval Policy
  4. Verify in warn mode, license scanning cannot be added
  5. Verify in enforce mode, if license scanning is added, warn mode is disabled

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #549783 (closed)

Edited by Alexander Turinske

Merge request reports

Loading