I deploy the application using Capistrano to /var/nginx/www/myapp. The
current code is always at /var/nginx/www/myapp/current.
So I changes the server’s root folder to /var/nginx/www/myapp/current
hoping that the location specs would be raktive to this folder. Since
then I get the “No input file specified.” error.
I also have fastcgi_param SCRIPT_FILENAME
$document_root$fastcgi_script_name;
I have php running using:
php-cgi -b 127.0.0.1:9000
My conf file is:
server {
listen 82 default;
## SSL directives might go here
server_name localhost 127.0.0.1 *;
root /cygdrive/e/xampp/htdocs/getit/src/myapp;
error_log /cygdrive/e/nginx.error.log notice;
access_log /cygdrive/e/nginx.access.log ;
rewrite_log on;
location / {
index index.html index.php; ## Allow a static html file to
be shown first
try_files $uri $uri/ @magehandler; ## If missing pass the
URI to Magento’s front handler
}
## These locations would be hidden by .htaccess normally
location ^~ /app/ { deny all; }
location ^~ /includes/ { deny all; }
location ^~ /lib/ { deny all; }
location ^~ /media/downloadable/ { deny all; }
location ^~ /pkginfo/ { deny all; }
location ^~ /report/config.xml { deny all; }
location ^~ /var/ { deny all; }
location ^~ /. { ## Disable .htaccess and other hidden files
return 404;
}
#Any request that does not match the regex locations below is sent
here
location @handler { ## Magento uses a common front handler
rewrite / /index.php$1 last;
}
location @magehandler { ## Magento uses a common front handler
rewrite (.*) /index.php$1 last;
}
#The more-specific regex are at the top.
#The regex's are evaluated in the order in which they appear.
location ~ .php.*$ { ## Execute PHP scripts
proxy_read_timeout 120;
proxy_connect_timeout 120;
expires off; ## Do not cache dynamic content
fastcgi_pass 127.0.0.1:9000;
#fastcgi_param HTTPS $fastcgi_https;
fastcgi_param SCRIPT_FILENAME