Skip to content

WIP: Allow global read-only user (like admin)

Brian Pearce requested to merge brianp/gitlab-ce:19737-global-read-only into master

What does this MR do?

  • Enhances the management of Admins to offer a "Read Only" type role that allows a user full read only access to all resources.
  • Removes the admin boolean from User.
  • Adds a role_type enum on User that accepts Default, Admin, & Auditor
  • Removes UI in the admin interface for editing, and creating new resources when logged in as an editor.
  • Adds authorization for user actions in the admin interface.
  • Adds authorization for controller actions in the admin namespace

Are there points in the code the reviewer needs to double check?

Migrations should be double checked. With a specific concern about the down migration in db/migrate/20160908105417_drop_admin_from_users.rb where an index is re-added to a previously dropped column.

Why was this MR needed?

The compliance department of a customer wants to run tests against the entire GitLab base to ensure users are complying with password, credit card, and other sensitive data policies. Without giving them full admin privileges.

Screenshots (if relevant)

Does this MR meet the acceptance criteria?

What are the relevant issue numbers?

Merge request reports