Commit 267ee92c authored by Nick Thomas's avatar Nick Thomas

Merge branch 'alipniagov/add_project_imports_direct_upload_route' into 'master'

Add route for project imports direct upload

See merge request gitlab-org/gitlab-workhorse!459
parents 8c2d2f5c 2e9fd811
......@@ -216,6 +216,7 @@ func (u *upstream) configureRoutes() {
route("POST", apiPattern+`v4/projects/[0-9]+/wikis/attachments\z`, uploadAccelerateProxy),
route("POST", apiPattern+`graphql\z`, uploadAccelerateProxy),
route("POST", apiPattern+`v4/groups/import`, upload.Accelerate(api, signingProxy)),
route("POST", apiPattern+`v4/projects/import`, upload.Accelerate(api, signingProxy)),
// Explicitly proxy API requests
route("", apiPattern, proxy),
......
......@@ -137,6 +137,7 @@ func TestAcceleratedUpload(t *testing.T) {
{"POST", `/api/graphql`, false},
{"PUT", "/api/v4/projects/9001/packages/nuget/v1/files", true},
{"POST", `/api/v4/groups/import`, true},
{"POST", `/api/v4/projects/import`, true},
}
for _, tt := range tests {
......
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