Zeokat I'm running VestaCP, however I'm running the Apach2 + Nginx proxy setup so it might not even be related. I was getting Error 404 first, running at chown -R user:www-data
solves it for me.
On the other issue though, fastcgi_pass
should not be necessary, unless Vesta specifically requires it.
Check so that index.php is in the index line.
root /usr/share/nginx/www;
index index.php index.html index.htm;
location ~ \.php$ {
try_files $uri =404;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
# NOTE: You should have "cgi.fix_pathinfo = 0;" in php.ini
# With php5-cgi alone:
#fastcgi_pass 127.0.0.1:9000;
# With php5-fpm:
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
}
Check /etc/php5/fpm/php.ini and make sure cgi.fix_pathinfo is set to 0.
And most important, do NOT forget to restart Nginx & PHP to make the changes take effect.
Keep in mind that these lines are for PHP5, you have to change them if you're running PHP7.
I would assume that it does download ALL .php files instead of executing them? Not just the admin.php? ?