summaryrefslogtreecommitdiff
path: root/config/routes
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-11-19 08:27:35 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-11-19 08:27:35 +0000
commit7e9c479f7de77702622631cff2628a9c8dcbc627 (patch)
treec8f718a08e110ad7e1894510980d2155a6549197 /config/routes
parente852b0ae16db4052c1c567d9efa4facc81146e88 (diff)
downloadgitlab-ce-7e9c479f7de77702622631cff2628a9c8dcbc627.tar.gz
Add latest changes from gitlab-org/gitlab@13-6-stable-eev13.6.0-rc42
Diffstat (limited to 'config/routes')
-rw-r--r--config/routes/group.rb12
-rw-r--r--config/routes/import.rb2
-rw-r--r--config/routes/merge_requests.rb1
-rw-r--r--config/routes/project.rb12
4 files changed, 26 insertions, 1 deletions
diff --git a/config/routes/group.rb b/config/routes/group.rb
index 33464cf3b55..e90be482bbd 100644
--- a/config/routes/group.rb
+++ b/config/routes/group.rb
@@ -107,6 +107,7 @@ constraints(::Constraints::GroupUrlConstrainer.new) do
end
resources :container_registries, only: [:index, :show], controller: 'registry/repositories'
+ resource :dependency_proxy, only: [:show, :update]
end
scope(path: '*id',
@@ -119,3 +120,14 @@ constraints(::Constraints::GroupUrlConstrainer.new) do
delete '/', action: :destroy
end
end
+
+# Dependency proxy for containers
+# Because docker adds v2 prefix to URI this need to be outside of usual group routes
+scope format: false do
+ get 'v2', to: proc { [200, {}, ['']] } # rubocop:disable Cop/PutGroupRoutesUnderScope
+
+ constraints image: Gitlab::PathRegex.container_image_regex, sha: Gitlab::PathRegex.container_image_blob_sha_regex do
+ get 'v2/*group_id/dependency_proxy/containers/*image/manifests/*tag' => 'groups/dependency_proxy_for_containers#manifest' # rubocop:todo Cop/PutGroupRoutesUnderScope
+ get 'v2/*group_id/dependency_proxy/containers/*image/blobs/:sha' => 'groups/dependency_proxy_for_containers#blob' # rubocop:todo Cop/PutGroupRoutesUnderScope
+ end
+end
diff --git a/config/routes/import.rb b/config/routes/import.rb
index 3ee44aa8659..557d7fe7143 100644
--- a/config/routes/import.rb
+++ b/config/routes/import.rb
@@ -69,7 +69,7 @@ namespace :import do
post :authorize
end
- resource :bulk_import, only: [:create] do
+ resource :bulk_imports, only: [:create] do
post :configure
get :status
end
diff --git a/config/routes/merge_requests.rb b/config/routes/merge_requests.rb
index b2635a7fa74..c11e5a5c3d9 100644
--- a/config/routes/merge_requests.rb
+++ b/config/routes/merge_requests.rb
@@ -47,6 +47,7 @@ resources :merge_requests, concerns: :awardable, except: [:new, :create, :show],
collection do
get :diff_for_path
post :bulk_update
+ post :export_csv
end
resources :discussions, only: [:show], constraints: { id: /\h{40}/ } do
diff --git a/config/routes/project.rb b/config/routes/project.rb
index eae217de1ac..2e61bc8175e 100644
--- a/config/routes/project.rb
+++ b/config/routes/project.rb
@@ -85,6 +85,7 @@ constraints(::Constraints::ProjectUrlConstrainer.new) do
namespace :ci do
resource :lint, only: [:show, :create]
+ resource :pipeline_editor, only: [:show], controller: :pipeline_editor, path: 'editor'
resources :daily_build_group_report_results, only: [:index], constraints: { format: /(csv|json)/ }
end
@@ -264,6 +265,8 @@ constraints(::Constraints::ProjectUrlConstrainer.new) do
resources :functions, only: [:index]
end
+ resources :terraform, only: [:index]
+
resources :environments, except: [:destroy] do
member do
post :stop
@@ -400,6 +403,11 @@ constraints(::Constraints::ProjectUrlConstrainer.new) do
#
# Templates
#
+ get '/templates/:template_type' => 'templates#index', # rubocop:todo Cop/PutProjectRoutesUnderScope
+ as: :templates,
+ defaults: { format: 'json' },
+ constraints: { template_type: %r{issue|merge_request}, format: 'json' }
+
get '/templates/:template_type/:key' => 'templates#show', # rubocop:todo Cop/PutProjectRoutesUnderScope
as: :template,
defaults: { format: 'json' },
@@ -436,6 +444,10 @@ constraints(::Constraints::ProjectUrlConstrainer.new) do
end
post 'alerts/notify', to: 'alerting/notifications#create' # rubocop:todo Cop/PutProjectRoutesUnderScope
+ post 'alerts/notify/:name/:endpoint_identifier', # rubocop:todo Cop/PutProjectRoutesUnderScope
+ to: 'alerting/notifications#create',
+ as: :alert_http_integration,
+ constraints: { endpoint_identifier: /[A-Za-z0-9]+/ }
draw :legacy_builds