Skip to content

Set compliance framework during project creation

What does this MR do and why?

This MR adds a feature that enables users to set a default compliance framework for a group and that framework is applied to all the projects created under that group.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

  1. Ensure that you have a Gitlab Ultimate license.
  2. Create a group.
  3. Create compliance frameworks for that group by navigating to Group Settings > General > Compliance frameworks.
  4. Create a new project named 'Project A' under this group. Ensure that the compliance framework is not added to this project.
  5. Set a default framework for the group. Since the ability to do this using GraphQL is still under development and will be a separate MR, therefore, we can use rails console for now.
g = Group.find(<group_id>)
frameworks = g.compliance_management_frameworks
g.namespace_settings.update!(default_compliance_framework_id: frameworks.last.id)
  1. Create a new project named 'Project B' under this group. Ensure that the default compliance framework is added to this project.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #375036 (closed)

Merge request reports

Loading