Created
February 12, 2012 04:47
-
-
Save orther/1806414 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
| server { | |
| listen 8118; | |
| server_name website.com www.website.com; | |
| root /var/www/website/www; | |
| expires 1M; | |
| # route requests to front controller | |
| location / { | |
| rewrite ^(.+)$ /index.php?__rlquery=$uri last; | |
| } | |
| # static content | |
| location ~ ^/(_css|_images|_js|_files|_swf) { | |
| access_log off; | |
| expires max; | |
| } | |
| # front controller routed to php-fpm | |
| location ~ ^/index\.php$ { | |
| expires off; | |
| include /etc/nginx/fastcgi_params; | |
| fastcgi_pass 127.0.0.1:9000; | |
| fastcgi_index index.php; | |
| fastcgi_param QUERY_STRING $query_string; | |
| fastcgi_param SCRIPT_FILENAME /var/www/website/www/index.php; | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment