Add "No one" option to "Roles allowed to create subgroups" group setting

Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.

Problem

The group setting Roles allowed to create subgroups (subgroup_creation_level) only offers two options:

  • Owners (default)
  • Maintainers and Owners

There is no way to prevent subgroup creation entirely. Group Owners always retain the ability to create subgroups.

Proposal

Mirror the solution used for the Roles allowed to create projects setting (project_creation_level), which is a dropdown that includes a No one option.

  • Add a No one option to the Roles allowed to create subgroups dropdown in Group Settings > General > Permissions and group features
  • Support the corresponding value in the subgroup_creation_level attribute in the Groups API
  • When set to No one, nobody (including Owners) can create subgroups in the group

Further details

The equivalent project creation setting already supports noone as a value, so the implementation can follow the same pattern for the enum, API validation, policy checks, and UI dropdown.

Edited by 🤖 GitLab Bot 🤖