Add organization settings toggle for the Policy Store experiment

What does this MR do and why?

Frontend half of the per-organization Policy Store opt-in — the settings toggle. Stacked on !251443 (merged) (the backend: setting, gating, and the policyStoreExperimentEnabled mutation argument); targets its branch so the diff shows only this change — retarget to master once it merges.

  • Organization owners opt in from Settings > General > Policy Store — a new EE-only section (injected through ee_else_ce + a slot in the CE app, inside the search-settings root so section search keeps working) with a toggle that saves through the policyStoreExperimentEnabled argument on organizationUpdate. The section renders only while the instance-wide gates pass.
  • Why a per-organization setting at all: confirmed with Alan — some customers do not allow experimental features and need an option to keep them disabled.
  • The toggle is disabled while its mutation is in flight (no concurrent saves), reverts on error, and success/error alerts scroll into view since the section sits at the bottom of the page.

References

Screenshots or screen recordings

Recording (3x speed, GDK org first): Policy Store section on org general settings → toggle on → success alert → /o/first/-/security/policy_store loads with the existing policy → toggle off → the same page 404s and the nav item disappears → toggle back on.

How to set up and validate locally

  1. Enable security_policies_v2 and the policy_store_experiment_enabled application setting (Ultimate license).
  2. Enable ui_for_organizations — the /o/... organization UI (including the settings page with the new toggle) is behind this flag.
  3. curl an org policy store route — 404 Not Found.
  4. As an org owner, open Settings > General > Policy Store and turn on Enable the Policy Store experiment.
  5. The same route now answers, and /o/<org>/-/security/policy_store renders; toggling off returns it to 404.

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist.

Edited by Alexander Turinske

Merge request reports

Loading
Loading