Commit f407257d authored by Nick Thomas's avatar Nick Thomas

Merge branch 'nuget-object-storage-upload-route' into 'master'

Add NuGet route for package uploads

See merge request gitlab-org/gitlab-workhorse!441
parents 62409786 5c19d848
...@@ -207,6 +207,9 @@ func (u *upstream) configureRoutes() { ...@@ -207,6 +207,9 @@ func (u *upstream) configureRoutes() {
// Conan Artifact Repository // Conan Artifact Repository
route("PUT", apiPattern+`v4/packages/conan/`, filestore.BodyUploader(api, proxy, nil)), route("PUT", apiPattern+`v4/packages/conan/`, filestore.BodyUploader(api, proxy, nil)),
// NuGet Artifact Repository
route("PUT", apiPattern+`v4/projects/[0-9]+/packages/nuget/`, filestore.BodyUploader(api, proxy, nil)),
// We are porting API to disk acceleration // We are porting API to disk acceleration
// we need to declare each routes until we have fixed all the routes on the rails codebase. // we need to declare each routes until we have fixed all the routes on the rails codebase.
// Overall status can be seen at https://gitlab.com/groups/gitlab-org/-/epics/1802#current-status // Overall status can be seen at https://gitlab.com/groups/gitlab-org/-/epics/1802#current-status
......
...@@ -328,5 +328,12 @@ func testPackageFileUpload(t *testing.T, resource string) { ...@@ -328,5 +328,12 @@ func testPackageFileUpload(t *testing.T, resource string) {
} }
func TestPackageFilesUpload(t *testing.T) { func TestPackageFilesUpload(t *testing.T) {
testPackageFileUpload(t, `/api/v4/packages/conan/v1/files`) routes := []string{
"/api/v4/packages/conan/v1/files",
"/api/v4/projects/9001/packages/nuget/v1/files",
}
for _, r := range routes {
testPackageFileUpload(t, r)
}
} }
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