feat(api): write Docker response code when using local proxy (#1192)

pull/1193/head
Anthony Lapenna 2017-09-14 11:09:36 +02:00 committed by GitHub
parent f96b70841f
commit d653391cdd
1 changed files with 3 additions and 0 deletions

View File

@ -34,6 +34,9 @@ func (proxy *socketProxy) ServeHTTP(w http.ResponseWriter, r *http.Request) {
w.Header().Add(k, v)
}
}
w.WriteHeader(res.StatusCode)
if _, err := io.Copy(w, res.Body); err != nil {
httperror.WriteErrorResponse(w, err, http.StatusInternalServerError, nil)
}