The objects in my Amazon S3 bucket are all of the content type application/octet-stream. Some of these objects are PDFs, sometimes images like JPG,
application/octet-stream
JPG
This is how you can set Content-Type for all files of type *.png
Content-Type
aws s3 cp \ s3://BUCKET-NAME/ \ s3://BUCKET-NAME/ \ --exclude '*' \ --include '*.png' \ --no-guess-mime-type \ --content-type="image/png" \ --metadata-directive="REPLACE" \ --recursive