X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/d9e48a19b82fe1d957686e0803c759553666237e..09a1ecf507df8ca110e6620efeb3593bc0d90192:/services/keep-web/handler.go diff --git a/services/keep-web/handler.go b/services/keep-web/handler.go index 6aeb7b9c48..b5c11e553c 100644 --- a/services/keep-web/handler.go +++ b/services/keep-web/handler.go @@ -25,7 +25,7 @@ import ( "git.curoverse.com/arvados.git/sdk/go/health" "git.curoverse.com/arvados.git/sdk/go/httpserver" "git.curoverse.com/arvados.git/sdk/go/keepclient" - log "github.com/Sirupsen/logrus" + log "github.com/sirupsen/logrus" "golang.org/x/net/webdav" ) @@ -141,26 +141,28 @@ var ( "Depth", "Destination", "If", "Lock-Token", "Overwrite", "Timeout", }, ", ") writeMethod = map[string]bool{ - "COPY": true, - "DELETE": true, - "LOCK": true, - "MKCOL": true, - "MOVE": true, - "PUT": true, - "RMCOL": true, - "UNLOCK": true, + "COPY": true, + "DELETE": true, + "LOCK": true, + "MKCOL": true, + "MOVE": true, + "PROPPATCH": true, + "PUT": true, + "RMCOL": true, + "UNLOCK": true, } webdavMethod = map[string]bool{ - "COPY": true, - "DELETE": true, - "LOCK": true, - "MKCOL": true, - "MOVE": true, - "OPTIONS": true, - "PROPFIND": true, - "PUT": true, - "RMCOL": true, - "UNLOCK": true, + "COPY": true, + "DELETE": true, + "LOCK": true, + "MKCOL": true, + "MOVE": true, + "OPTIONS": true, + "PROPFIND": true, + "PROPPATCH": true, + "PUT": true, + "RMCOL": true, + "UNLOCK": true, } browserMethod = map[string]bool{ "GET": true, @@ -216,7 +218,7 @@ func (h *handler) ServeHTTP(wOrig http.ResponseWriter, r *http.Request) { return } w.Header().Set("Access-Control-Allow-Headers", corsAllowHeadersHeader) - w.Header().Set("Access-Control-Allow-Methods", "COPY, DELETE, GET, MKCOL, MOVE, OPTIONS, POST, PROPFIND, PUT, RMCOL") + w.Header().Set("Access-Control-Allow-Methods", "COPY, DELETE, GET, LOCK, MKCOL, MOVE, OPTIONS, POST, PROPFIND, PROPPATCH, PUT, RMCOL, UNLOCK") w.Header().Set("Access-Control-Allow-Origin", "*") w.Header().Set("Access-Control-Max-Age", "86400") statusCode = http.StatusOK