add GET /config
This commit is contained in:
@@ -73,6 +73,9 @@ func registerWS(rest *restful.Container) {
|
||||
Doc("Sign a download set"))
|
||||
|
||||
// - configs API
|
||||
ws.Route(ws.GET("/config").To(wsFetchConfig).
|
||||
Produces(mime.JSON, mime.YAML).
|
||||
Doc("Fetch the current configuration"))
|
||||
ws.Route(ws.POST("/configs").To(wsUploadConfig).
|
||||
Consumes(mime.YAML, mime.JSON).Param(ws.BodyParameter("config", "The new full configuration")).
|
||||
Produces(mime.JSON).Writes(true).
|
||||
|
||||
Reference in New Issue
Block a user