Skip to content

Commit 76a9781

Browse files
author
Andrew Farries
committed
[usage] Set Content-Type header on PUT request
The signed upload URL only accepts requests with this Content-Type.
1 parent 2001f03 commit 76a9781

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

components/usage/pkg/contentservice/client.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ func (c *Client) UploadUsageReport(ctx context.Context, filename string, report
5353
return fmt.Errorf("failed to construct http request: %w", err)
5454
}
5555

56+
req.Header.Set("Content-Type", "application/json")
5657
req.Header.Set("Content-Encoding", "gzip")
5758

5859
log.Infof("Uploading %q to object storage...", filename)

0 commit comments

Comments
 (0)