Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
gitlab-ce
Commits
131ca31b
Commit
131ca31b
authored
May 07, 2018
by
Dylan Griffith
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add a comment about implementing proper policies for group runner permissions
parent
8f29d9c6
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
0 deletions
+5
-0
app/controllers/groups/runners_controller.rb
app/controllers/groups/runners_controller.rb
+3
-0
app/views/groups/runners/_group_runners.html.haml
app/views/groups/runners/_group_runners.html.haml
+2
-0
No files found.
app/controllers/groups/runners_controller.rb
View file @
131ca31b
class
Groups::RunnersController
<
Groups
::
ApplicationController
class
Groups::RunnersController
<
Groups
::
ApplicationController
# Proper policies should be implemented per
# https://gitlab.com/gitlab-org/gitlab-ce/issues/45894
before_action
:authorize_admin_pipeline!
before_action
:authorize_admin_pipeline!
before_action
:runner
,
only:
[
:edit
,
:update
,
:destroy
,
:pause
,
:resume
,
:show
]
before_action
:runner
,
only:
[
:edit
,
:update
,
:destroy
,
:pause
,
:resume
,
:show
]
def
show
def
show
...
...
app/views/groups/runners/_group_runners.html.haml
View file @
131ca31b
...
@@ -4,6 +4,8 @@
...
@@ -4,6 +4,8 @@
GitLab Group Runners can execute code for all the projects in this group.
GitLab Group Runners can execute code for all the projects in this group.
They can be managed using the
#{
link_to
'Runners API'
,
help_page_path
(
'api/runners.md'
)
}
.
They can be managed using the
#{
link_to
'Runners API'
,
help_page_path
(
'api/runners.md'
)
}
.
-# Proper policies should be implemented per
-# https://gitlab.com/gitlab-org/gitlab-ce/issues/45894
-
if
can?
(
current_user
,
:admin_pipeline
,
@group
)
-
if
can?
(
current_user
,
:admin_pipeline
,
@group
)
=
render
partial:
'ci/runner/how_to_setup_runner'
,
=
render
partial:
'ci/runner/how_to_setup_runner'
,
locals:
{
registration_token:
@group
.
runners_token
,
type:
'group'
}
locals:
{
registration_token:
@group
.
runners_token
,
type:
'group'
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment