From c8d90f904f1e86e7aa5fa2baa76c40c1b60c3a3c Mon Sep 17 00:00:00 2001 From: Smasherr Date: Tue, 3 Nov 2020 12:24:02 +0100 Subject: [PATCH] Remove empty Content-Type header Fixes #3288 Signed-off-by: Smasherr --- registry/client/repository.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/registry/client/repository.go b/registry/client/repository.go index 793a662d..0a2bfec1 100644 --- a/registry/client/repository.go +++ b/registry/client/repository.go @@ -757,7 +757,12 @@ func (bs *blobs) Create(ctx context.Context, options ...distribution.BlobCreateO return nil, err } - resp, err := bs.client.Post(u, "", nil) + req, err := http.NewRequest("POST", u, nil) + if err != nil { + return nil, err + } + + resp, err := bs.client.Do(req) if err != nil { return nil, err }