I have a WordPress website on AWS with 2 EC2 instances behind a load balancer. Then I have CloudFront directing to that load balancer and S3 handles my images.
We publish articles daily. When I visit the site, I then need need to reload the page to see new articles.
I set all of this up. However, I do not know CloudFront well enough to know how to diagnose or solve the issue. I'm only assuming it is CloudFront as no other caching tools are in use.
If it is CloudFront, what might be the issue? If not, then how should I proceed to solve this?
You can solve this by setting the TTL from the origin and just telling CloudFront to use the origin's cache headers.
Alternatively, you can do this just in CloudFront directly by
Path Patterns for Cache Behaviours is a very useful article