Implement multipart form rewriting to support upload offloading
-
This parses multipart form data and saves all found files as files in TempPath. TempPath is received from Rails by calling authorize request. The rewritten multipart form data contains
file.pathwhere the temporary file is stored, andfile.namethe original name of file as stored in Content-Disposition. The temporary file is removed afterwards, if it's not consumed by GitLab Rails. If the body is not multipart, forward request. -
All artifacts downloads are offloaded by exposing X-Sendfile-Type extension.