Add group level merge request approvals resource
-
Please check this box if this contribution uses AI-generated content (including content generated by GitLab Duo features) as outlined in the GitLab DCO & CLA. As a benefit of being a GitLab Community Contributor, you receive complimentary access to GitLab Duo.
This merge request adds a new Terraform resource called gitlab_group_level_mr_approvals that allows users to manage merge request approval settings at the GitLab group level. The resource provides configuration options for various approval behaviors, such as whether authors can approve their own merge requests, whether approvals are retained when new code is pushed, and whether approvers need to re-authenticate before approving.
A key feature is the keep_settings_on_destroy option, which controls what happens when the resource is deleted - users can choose to either preserve their approval settings (default) or reset them back to their original values. The resource includes validation to ensure certain conflicting settings aren't used together, like enabling selective code owner removals while retaining approvals on push.
The implementation includes comprehensive documentation with usage examples, import instructions, and detailed descriptions of all configuration options. It also includes test files to ensure the functionality works correctly. This gives GitLab administrators using Terraform a programmatic way to standardize and manage merge request approval policies across their organization's groups.
Fixes #1456 (closed)