Page 1 of 1
Nginx Caching Wordpress
Posted: Fri Feb 02, 2018 3:17 pm
by ahmed
Guys, been searching for a while and its time to ask
how can i enable nginx caching for wordpress on vestacp
i'm running on centos 7 with nginx and php-fpm no apache
from what i've been reading there's a template for nginx caching, but how can i change to this template?
the web template i'm using is wordpress2, but nothing gets cached.
so the question remains, how can i enable caching for wordpress when i'm running on nginx+php-fpm only?
Re: Nginx Caching Wordpress
Posted: Sat Feb 10, 2018 3:55 am
by noogen
Since no one is responding to this and message is getting old, I'm going to take a stab at it. What kind of caching are you looking for? Static content should already be served and browser cached. php-fpm is usually pretty efficient, but if you're looking for compiled php page cache then you have two options:
1. Redis working with w3-total-cache.
Instruction:
viewtopic.php?f=11&t=14647&p=63637&hilit=redis#p63637
2. fastcgi cache
This is the lesser/not common option. All I found on my search is this instruction in Russian:
viewtopic.php?f=29&t=15764&p=64967&hili ... che#p64967
You can probably find better instruction online. The point here is that, non of the two options are standard template in Vesta. You want to copy/duplicate wordpress2 templates (.tpl/.stpl) and add caching to it.
Re: Nginx Caching Wordpress
Posted: Sun Mar 18, 2018 10:41 am
by rhyker2u
noogen wrote: ↑Sat Feb 10, 2018 3:55 am
1. Redis working with w3-total-cache.
Instruction:
viewtopic.php?f=11&t=14647&p=63637&hilit=redis#p63637
You can probably find better instruction online. The point here is that, non of the two options are standard template in Vesta. You want to copy/duplicate wordpress2 templates (.tpl/.stpl) and add caching to it.
Good luck with finding one. Dare say my guide is the best ;) don't just read that particular snippet but everything above it too. Do check out this tip too:
viewtopic.php?f=11&t=14687
The bigger speed increases can be held by modifying php-fpm on-demand parameters. Will update my 'FTL' guide (the quoted link) accordingly one of these days. P.S. I no longer run w3-total-cache and switched to WP-Rocket or
https://wordpress.org/plugins/wp-fastest-cache/ ... and Redis keeps to run fine as it has its own WP plugin.
Re: Nginx Caching Wordpress
Posted: Sun Sep 09, 2018 7:47 pm
by valentine