Fix maintainers of group runner groups not able to see jobs
What does this MR do and why?
This MR fixes the bug where maintainers of group runner's groups are not able to see jobs associated with runner. It also adds tests for the :read_builds permission.
Changelog: fixed
References
Screenshots or screen recordings
| Before | After |
|---|---|
|
|
How to set up and validate locally
-
Log in with the root account to http://gdk.test:3000
-
Go to the shell in your GDK
gitlabdirectory and runbundle exec rake "gitlab:seed:runner_fleet[root, rf-, 40, 1000]". This will seed your GDK with some runners and jobs required for testing this MR. -
Now we need to find a group runner that has executed some jobs. For that we'll navigate to http://gdk.test:3000/admin/runners?runner_type[]=GROUP_TYPE and try to find a runner where
has a non-zero number. -
Click on the runner to check that the runner details page shows that the runner has jobs listed. Take note of the runner numerical ID.
-
Click on the assigned group in order to navigate to the group:
-
Click the spanner button:
-
Click
Manage access: -
Click
Invite members -
Choose a user, for example
Ira Botsford, and add it as a maintainer to the subgroup -
Impersonate the chosen user
-
Refresh the runner details page and confirm that the runner jobs are now visible. Some details might not be visible if the user does not have access to the project itself.
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.





