Role Based Access Control

Implementing RBAC in GitLab

< >

2. Implementing RBAC in GitLab

Understanding Roles and Permissions

In GitLab, roles are defined with varying levels of access to projects and resources. Key roles include:

  • Owner: Full control over the project, including permissions to manage settings, add/remove members, and delete the project.
  • Maintainer: Similar to owners but with restrictions on certain administrative actions (e.g., cannot delete the project).
  • Developer: Access to code, pipelines, and issues but restricted from managing project settings.
  • Reporter: Read-only access to the project, including issues, merge requests, and pipelines.
  • Guest: Limited access, primarily for viewing project information without the ability to make changes.

Role Assignment in GitLab

Roles can be assigned at both the project and group levels in GitLab, specifying the level of access each user or group has within that scope.

Configuring Roles in GitLab

  1. Navigate to Project Settings: Go to your project in GitLab and click on Manage > Members.

  2. Invite members: Add users or groups and assign them roles such as Owner, Maintainer, Developer, Reporter, or Guest.

    gitlab-roles.png

  3. Adjust Permissions: Customize permissions within each role based on project requirements.

Example: Assigning Roles in GitLab

Project: My Awesome Project

Owner: John Doe (john.doe@example.com )

Maintainer: Jane Smith (jane.smith@example.com )

Developer: Team Developers (developers@example.com )

Reporter: Reporter (reporter@example.com )

Guest: Public Access