mirror of
https://github.com/goharbor/harbor.git
synced 2024-10-01 23:07:39 +02:00
fix delete manifest route issue
The repository name contains blackslash, the mux router has to use the * to match the blackslash. Otherwise the caller(gc job) will get a 404. Signed-off-by: wang yan <wangyan@vmware.com>
This commit is contained in:
parent
1d03b8727a
commit
12c92dbfce
@ -33,6 +33,6 @@ func newRouter(conf config.Configuration) http.Handler {
|
|||||||
|
|
||||||
rootRouter.Path("/api/registry/gc").Methods(http.MethodPost).Handler(gc.NewHandler(conf.RegistryConfig))
|
rootRouter.Path("/api/registry/gc").Methods(http.MethodPost).Handler(gc.NewHandler(conf.RegistryConfig))
|
||||||
rootRouter.Path("/api/registry/blob/{reference}").Methods(http.MethodDelete).Handler(blob.NewHandler(conf.StorageDriver))
|
rootRouter.Path("/api/registry/blob/{reference}").Methods(http.MethodDelete).Handler(blob.NewHandler(conf.StorageDriver))
|
||||||
rootRouter.Path("/api/registry/{name}/manifests/{reference}").Methods(http.MethodDelete).Handler(manifest.NewHandler(conf.StorageDriver))
|
rootRouter.Path("/api/registry/{name:.*}/manifests/{reference}").Methods(http.MethodDelete).Handler(manifest.NewHandler(conf.StorageDriver))
|
||||||
return rootRouter
|
return rootRouter
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user