Copy Docker's response code through for raw stream.

This means when Docker says "101 UPGRADED" the proxy will say the
same, instead of "200 OK".  Docker 1.12 barfs if you do that.
This commit is contained in:
Bryan Boreham committed 2016-06-17 13:07:04 +01:00
1 parent ddd039761d
commit 56c275a9bf
1 file changed
+1 -1
+1 -1
View File
@@ -78,7 +78,7 @@ func doRawStream(w http.ResponseWriter, resp *http.Response, client *httputil.Cl
defer down.Close()
defer up.Close()
if _, err := down.Write([]byte("HTTP/1.1 200 OK\n")); err != nil {
if _, err := down.Write([]byte("HTTP/1.1 " + resp.Status + "\n")); err != nil {
Log.Warning(err)
return
}