Question
W3 Total Cache With Nginx - Config
I’ve seen a number of questions asked on this subject already, but I’ve yet to find a single quality tutorial, or proper set of answers.
How exactly are we supposed to configure W3 Total Cache with Nginx? I connect via SSH, and have a specific user who has complete access to my wordpress installation. This allowed W3 Total Cache to install, and create an nginx.config file on the root of my domain (/var/www/anightinburton.com/public_html). I’ve read of a number of things you should do from here, with no definitively clear answer on which is best, if any:
-It seems you can add an include, so that you have both your server block config, and your root config. Does the include go in the root to include the server block, or the other way around?
-Another thing I recently discovered, is that there is a path to config option at the bottom of the general tab for W3 Total Cache. It says if you leave it blank, the default will be used, which appears to be the root of your website. Could I add “/etc/nginx/sites-available/anightinburlington.com” there and simply have W3 write to my server block config? Is this a better route to take?
-I also see a ton of nginx config files that already include various W3 settings, but they’re all extremely complex looking to me, and I’m afraid of using them as I have a unique setup (Wordpress in a directory of its own, but served on the root), which has already required some odd changes to my try files in the server block config.
Can someone please offer some guidance on how I should set this up? DigitalOcean has amazing community written tutorials, but this specific subject is greatly lacking. Thanks for any advice, it’s much appreciated.
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
×