Skip to content

Hide Register Runner button when user is not permitted to do the action

Kent Japhet Ballon requested to merge auditor-hide-register-runner-button into master

What does this MR do and why?

Describe in detail what your merge request does and why.

Closes #367520 (closed)

Screenshots or screen recordings

These are strongly recommended to assist reviewers and reduce the time to merge your change.

auditor-enable-group-cicd-runners auditor-hide-register-runner-button
auditor-hide-register-runner-button-1 auditor-hide-register-runner-button-2

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

  1. Switch to the master branch and visit GitLab in your browser. Login as an admin user and attempt to visit the runners in a group https://gitlab.example.com/groups/<GROUP>/-/runners. As an admin, you should be able to view this page and see the Register Runner button.
  2. Impersonate an auditor account and attempt to visit https://gitlab.example.com/groups/<GROUP>/-/runners. As an auditor, you should be able to view this page but not see the Register Runner button.
  3. Switch to the auditor-hide-register-runner-button branch.
  4. In the address bar, attempt to visit https://gitlab.example.com/groups/<GROUP>/-/runners. As an auditor, the Register Runner button should no longer be visible

Note that this MR is a follow up to !91553 (merged) where it was agreed that the Register Runner button should not be visible to auditor users.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Kent Japhet Ballon

Merge request reports

Loading