Skip to content

Integrate instance-level with group-level MR approval settings

Max Woolf requested to merge 325279-group-level-mr into master

What does this MR do?

  • Adds an interface that resolves instance and group MR settings to a single value along with information about whether or not those values are locked.
  • Updates the /group/:id/group_merge_request_setting API endpoint to represent those new values. e.g.:
{
  "allow_author_approval": {
    "name": "allow_author_approval",
    "value": false,
    "locked": true,
    "inherited_from": "instance"
  },
  "allow_committer_approval": {
    "name": "allow_committer_approval",
    "value": true,
    "locked": false,
    "inherited_from": null
  },
  "allow_overrides_to_approver_list_per_merge_request": {
    "name": "allow_overrides_to_approver_list_per_merge_request",
    "value": true,
    "locked": false,
    "inherited_from": null
  },
  "retain_approvals_on_push": {
    "name": "retain_approvals_on_push",
    "value": true,
    "locked": null,
    "inherited_from": null
  },
  "require_password_to_approve": {
    "name": "require_password_to_approve",
    "value": false,
    "locked": null,
    "inherited_from": null
  }
}
  • Still behind a default-off feature flag, so no breaking changes here.

Screenshots or Screencasts (strongly suggested)

How to setup and validate locally (strongly suggested)

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

Does this MR contain changes to processing or storing of credentials or tokens, authorization and authentication methods or other items described in the security review guidelines? If not, then delete this Security section.

  • Label as security and @ mention @gitlab-com/gl-security/appsec
  • The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • Security reports checked/validated by a reviewer from the AppSec team

Related to #325279 (closed)

Edited by Max Woolf

Merge request reports