Created
September 25, 2012 22:47
-
-
Save kmccarth/3784932 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
To set up nginx as a reverse caching proxy, copy the nginx_configs folder from this repo and follow these steps: | |
sudo -s nginx=stable # use nginx=development for latest development version | |
add-apt-repository ppa:nginx/$nginx | |
apt-get update | |
apt-get install nginx | |
sudo apt-get install libapache2-mod-rpaf | |
sudo a2enmod rpaf | |
copy etc_apache2_ports.conf to etc/apache2/ports.conf copy etc_apache2_sitesavailable_default to etc/apache2/sites-available/default copy etc_nginx_nginx.conf to etc/nginx/nginx.conf | |
ensure any lines in apache2.conf or apache2/sites-available/default like the below: | |
AllowOverride None | |
are changed to | |
AllowOverride All | |
check for any lines in .htaccess which set the Cache-Control header as below, and remove them: | |
Header set Cache-Control "no-store, no-cache, must-revalidate, max-age=0" | |
Configs were taken from the following pages: | |
http://wordpress.org/extend/plugins/nginx-proxy-cache-integrator/installation/ http://www.djm.org.uk/wordpress-nginx-reverse-proxy-caching-setup/ | |
The above linked plugin should be used with this configuration. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment