Commit f091272f authored by Grzegorz Bizon's avatar Grzegorz Bizon

Move artifacts controller level up

This reverts nesting artifacts controller in builds module.
parent a96d45c6
class Projects::Builds::ArtifactsController < Projects::ApplicationController
class Projects::ArtifactsController < Projects::ApplicationController
layout 'project'
before_action :authorize_download_build_artifacts!
......@@ -14,7 +14,7 @@ class Projects::Builds::ArtifactsController < Projects::ApplicationController
send_file artifacts_file.path, disposition: 'attachment'
end
def view
def browse
@metadata = build.artifacts_metadata
end
......
......@@ -608,13 +608,9 @@ Rails.application.routes.draw do
post :retry
end
scope module: :builds do
resource :artifacts, only: [] do
collection do
get :download
get 'view(/:path)', as: :view, to: 'artifacts#view'
end
end
resource :artifacts, only: [] do
get :download
get 'browse(/*path)', action: :browse, as: :browse
end
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment