We have a Wordpress site hosted on an Amazon Web Services EC2 instance using elastic load balancing. I'm running into a frustrating problem where it seems like every time I refresh the browser, sometimes it shows the updated site and sometimes it shows an older, cached version of the site. That goes for content edits made on the frontpage, changes to wp-config, and changes to .htaccess and httpd.conf.
Example 1: I added a subdomain in httpd.conf and sometimes I'll go to subdomain.example.com and it'll show the test file I put into the subdomain folder, but other times I'm redirected to the main website (DNS has a wildcard subdomain pointing to the ELB A record)
Example 2: I added a force-www redirect in .htaccess and sometimes it redirects, sometimes it doesn't.
Example 3: The front page sometimes shows the main three images we switched the homepage to, but sometimes shows the main three images from last month.
Example 4: I changed a wp-config file to say site-url="www.site.com" and home="www.site.com" (previously was site-url="site.com" and home="www.site.com"), but when I go to WP's settings page, sometimes it shows my changes, but other times it shows the old configuration.
I've tried everything from clearing the browser cache/cookies, using different browsers, using different computers from different locations, restarting httpd - the problem persists. I have a feeling it has something to do with the ELB and several instances caching?
Thanks in advance!