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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gitlab-ce
Commits
a96d45c6
Commit
a96d45c6
authored
Dec 17, 2015
by
Grzegorz Bizon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add view action to artifacts controller
parent
79fe18d9
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
3 deletions
+10
-3
app/controllers/projects/builds/artifacts_controller.rb
app/controllers/projects/builds/artifacts_controller.rb
+4
-0
app/models/ci/build.rb
app/models/ci/build.rb
+0
-2
app/views/projects/builds/artifacts/view.html.haml
app/views/projects/builds/artifacts/view.html.haml
+4
-0
config/routes.rb
config/routes.rb
+2
-1
No files found.
app/controllers/projects/builds/artifacts_controller.rb
View file @
a96d45c6
...
...
@@ -14,6 +14,10 @@ class Projects::Builds::ArtifactsController < Projects::ApplicationController
send_file
artifacts_file
.
path
,
disposition:
'attachment'
end
def
view
@metadata
=
build
.
artifacts_metadata
end
private
def
build
...
...
app/models/ci/build.rb
View file @
a96d45c6
...
...
@@ -336,8 +336,6 @@ module Ci
project
.
execute_services
(
build_data
.
dup
,
:build_hooks
)
end
private
def
yaml_variables
...
...
app/views/projects/builds/artifacts/view.html.haml
0 → 100644
View file @
a96d45c6
-
page_title
"
#{
@build
.
name
}
(#
#{
@build
.
id
}
)"
,
'Build artifacts'
-
header_title
project_title
(
@project
,
"Build artifacts"
,
namespace_project_build_path
(
@project
.
namespace
,
@project
,
@build
))
=
@metadata
.
inspect
config/routes.rb
View file @
a96d45c6
...
...
@@ -609,9 +609,10 @@ Rails.application.routes.draw do
end
scope
module: :builds
do
resource
s
:artifacts
do
resource
:artifacts
,
only:
[]
do
collection
do
get
:download
get
'view(/:path)'
,
as: :view
,
to:
'artifacts#view'
end
end
end
...
...
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