I'm using CloudFront and have an S3 bucket with some css, images and js:
I checked on webpagetest and saw my css, images and js are not being gzipped, for example, all.js, the 8th entry here:
I read that I must create a cache behaviour, so I did, compressing, or so I thought, all js automatically:
However, still the same results in webpagetest. I invalidated my js, waited but still I get the same result.
I'm clearly missing something here! I haven't gzipped my files in the S3 bucket - is that a problem? Can anybody spot my mistake(s) and tell me how to have my css, images and js from CloudFront gzipped? Thanks.
I hope this helps somebody. The problem is now solved.
I made the following Invalidation:
And then deleted the old Behaviours and added 3 new ones:
Now all my resources are Gzipped: