Update package namespace settings permissions
🍭 What does this MR do and why?
Changes the required permissions to change namespace/group-level package settings from Developer to Maintainer.
This MR also refactors the permissions to use admin_package
rather than have a separate subset of permissions for package settings. This is more aligned with the rest of the permissions throughout GitLab.
🍬 Screenshots or screen recordings
💻 How to set up and validate locally
- Create a group (or pick an existing one)
- Create a user
- Add the user to the group as a Developer
- While logged in as the Developer user, use the graphql explorer: http://gdk.test:3000/-/graphql-explorer to try to update the namespace package settings using the query below:
mutation { updateNamespacePackageSettings(input: { namespacePath: "<your-namespace-full-path>", genericDuplicatesAllowed:true, genericDuplicateExceptionRegex: "asdf.*" }) { packageSettings { genericDuplicatesAllowed genericDuplicateExceptionRegex } } }
- The request should be unsuccessful
- Optionally, you can log back in as the root user or owner/maintainer of the group and make the request again, it should be successful.
📐 MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related: #350682 (closed)
Edited by Steve Abrams