Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

When using S3 to server web site content (both in conjunction with CloudFront and not) you will may want to set Cache Control headers for browsers or CloudFront to use.

Code Block
something
$ aws s3api put-object --bucket mybucket --key index.html --cache-control max-age=3600 --body www-files/index.html 
{
    "ETag": "\"63525d1b04aeb5d301de2acc498480b3\"", 
    "ServerSideEncryption": "AES256"
}