mirror of
https://github.com/distribution/distribution
synced 2024-11-12 05:45:51 +01:00
Merge pull request #2338 from proppy/patch-1
Registry: Fix content-type for PushImageJSONIndex
This commit is contained in:
commit
e5dcf37f11
@ -504,6 +504,7 @@ func (r *Registry) PushImageJSONIndex(indexEp, remote string, imgList []*ImgData
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
req.Header.Add("Content-type", "application/json")
|
||||||
req.SetBasicAuth(r.authConfig.Username, r.authConfig.Password)
|
req.SetBasicAuth(r.authConfig.Username, r.authConfig.Password)
|
||||||
req.ContentLength = int64(len(imgListJSON))
|
req.ContentLength = int64(len(imgListJSON))
|
||||||
req.Header.Set("X-Docker-Token", "true")
|
req.Header.Set("X-Docker-Token", "true")
|
||||||
|
Loading…
Reference in New Issue
Block a user