nginx + wordpress rewrite question
Edho P Arief
edhoprima at gmail.com
Tue Feb 16 16:30:19 MSK 2010
On Tue, Feb 16, 2010 at 7:28 PM, Jaime Magiera
<jaime at sensoryresearch.net> wrote:
> OK, I appreciate all your help. It seems I've messed things up even more now. While attempting to translate what you folks provided, I've now got a configuration that doesn't work right even with standard wordpress links. If I try to go to the default URL for the blog, I end up getting a download of the php instead of the page displaying (however, some other wordpress URLS work?). I'm really not getting nginx. Can someone perhaps point out what it is that I'm not getting. Taking this project over cold with no nginx experience is becoming a very frustrating experience.
>
> /////////////////////////
>
> worker_processes 1;
>
> events {
> worker_connections 1024;
> }
>
> http {
> passenger_root /opt/ruby-enterprise-1.8.6-20090610/lib/ruby/gems/1.8/gems/passenger-2.2.2;
> passenger_ruby /opt/ruby-enterprise-1.8.6-20090610/bin/ruby;
> passenger_default_user playsay;
> include mime.types;
> default_type application/octet-stream;
>
> sendfile on;
> keepalive_timeout 65;
>
> gzip on;
>
> client_max_body_size 512m;
> server {
> listen 80;
> server_name www.playsay.com;
> root /home/playsay/apps/playsay/current/public;
> access_log /home/playsay/logs/access.log;
> error_log /home/playsay/logs/error.log;
> passenger_enabled on;
> location /files {
> root /home/playsay;
> internal;
> }
>
> index index.php index.html;
> location ~ \.php$ {
> fastcgi_index index.php;
> fastcgi_pass localhost:9000;
> fastcgi_param SCRIPT_FILENAME
> $document_root$fastcgi_script_name;
> include /opt/nginx/conf/fastcgi_params;
> }
>
> location /blog {
> passenger_enabled off;
> index index.html index.htm index.php;
> try_files $uri $uri/ @blog;
> }
>
> location @blog {
> include /opt/nginx/conf/fastcgi_params;
> fastcgi_param SCRIPT_FILENAME $document_root/blog/index.php;
> fastcgi_param QUERY_STRING q=$uri&$args;
> }
you forgot fastcgi_pass.
and QUERY_STRING is not needed.
>
> ...
> }
> }
>
>
> Jaime Magiera
>
> Sensory Research, Inc.
> http://www.sensoryresearch.net
>
>
>
>
>
>
>
>
> _______________________________________________
> nginx mailing list
> nginx at nginx.org
> http://nginx.org/mailman/listinfo/nginx
>
--
O< ascii ribbon campaign - stop html mail - www.asciiribbon.org
More information about the nginx
mailing list