Manifest PUT should return 202 Accepted status

Signed-off-by: Stephen J Day <stephen.day@docker.com>
This commit is contained in:
Stephen J Day 2015-02-03 18:27:40 -08:00
parent 1089cae282
commit 1f06e4f816
2 changed files with 3 additions and 2 deletions

View file

@ -336,8 +336,7 @@ func TestManifestAPI(t *testing.T) {
}
resp = putManifest(t, "putting signed manifest", manifestURL, signedManifest)
checkResponse(t, "putting signed manifest", resp, http.StatusOK)
checkResponse(t, "putting signed manifest", resp, http.StatusAccepted)
resp, err = http.Get(manifestURL)
if err != nil {

View file

@ -92,6 +92,8 @@ func (imh *imageManifestHandler) PutImageManifest(w http.ResponseWriter, r *http
w.WriteHeader(http.StatusBadRequest)
return
}
w.WriteHeader(http.StatusAccepted)
}
// DeleteImageManifest removes the image with the given tag from the registry.