Thanks for your quick response!
1. We are using the standard WordPress Docker image, which runs with Apache2.
2. No plugin-related errors.
3. Yes, that is enabled. What does that mean?
If the problems only occur on the front page, then there is most likely a conflict with the Critical CSS setting somewhere, and the solution is to disable it.
If not, then the problem may be that the pages are cached somewhere else (not in the PageSpeed Ninja plugin), so that when PageSpeed Ninja considers that certain optimized style and script files are outdated and can be safely deleted, the pages that use them are still available through some other cache (webserver’s cache, another caching plugin, caching frontend proxy, etc.). As far as I can remember, the wordpress:apache container itself does not use caching. So, do you have any other optimization or caching-related plugins installed?
Okay, I have disabled the Crirical CSS setting. Let’s see if it helps!
Thank you!
Right now I see an inconsistency on your site (some /s/*.css files don’t exist) between the page cache and the internal cache that synchronizes the time-to-live of files in the /s directory (it turns out that there is a page cache file, there is an internal cache file, but there are no files referenced by the internal cache). In such a situation, you need to Clear All the Cache and the Page Cache in the Troubleshooting section (see Advanced Settings).
I’ll try to run some more tests with the Docker container and a short time-to-live value, maybe I’ll be able to reproduce this bug eventually. Tell me, do you mount additional directories or volumes when you start docker? If so, how do you mount them (volume or bind)? And are there any symbolic links at the root of the site (or higher in the directory hierarchy)?
Also, could you tell, what your value is for the “Caching Time-to-live” parameter (see Advanced Settings)? It is also possible that you manually cleared the cache earlier, but did not clear the page cache in the Troubleshooting section. This can also cause inconsistencies, but most likely the problem is somewhere else.
Unfortunately, my experiments with Docker and the debug build of the PageSpeed Ninja plugin didn’t reveal any issues with the page cache. The cache cleaner script correctly removes the internal cache and related files in the /s directory.
I used a standard docker-compose.yml from https://hub.docker.com/_/wordpress. Could you provide more details about your specific Docker settings or any additional plugins that might be affecting caching?
Thanks a lot for diving into our issue again. Especially since we still experience the same problem every few days.
As you describe, manually clearing the cache solves it. But only for that moment.
We are using the official Docker WordPress image without anything fancy. No special configuration. /var/www/html as bind mount, nothing else. No symlinks.
Would taking a look at our other plugins help?
Would taking a look at our other plugins help?
Could you send the list of active plugins to hello@pagespeed.ninja? I’ll try to check which ones might be interfering with PageSpeed Ninja.
Also, could you check the container logs for possible errors (maybe an error in the PHP file, or execution timeout, etc.)?