• Introducing WebPros Cloud - a fully managed infrastructure platform purpose-built to simplify the deployment of WebPros products !  WebPros Cloud enables you to easily deliver WebPros solutions — without the complexity of managing the infrastructure.
    Join the pilot program today!
  • Support for BIND DNS has been removed from Plesk for Windows due to security and maintenance risks.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS.

Resolved Onyx 17.8, FPM+nginx Wordpress permalinks not working

Nick

New Pleskian
I've got Plesk 17.8 on linux and a Wordpress site using PHP 7.1 running as FPM served by nginx. I also have proxy mode and smart static file processing turned on and the following in the addtional nginx directives:

if (!-e $request_filename) {
set $test P;
}
if ($uri !~ ^/(plesk-stat|webstat|webstat-ssl|ftpstat|anon_ftpstat|awstats-icon|internal-nginx-static-location)) {
set $test "${test}C";
}
if ($test = PC) {
rewrite ^/(.*)$ /index.php?$1;
}

When enabling WP permalinks I get a 403 forbidden from nginx. In the proxy_error_log I get this:

2018/09/14 15:41:26 [error] 26696#0: *1 directory index of "/var/www/vhosts/example.com/httpdocs/test/" is forbidden, client: xxx.xxx.xxx.xxx, server: example.com, request: "GET /test/ HTTP/1.1", host: "example.com"

I've searched around but all the solutions I've tried do not work. I cannot get permalinks to work with this configuration. If permalinks are turned off, everything works great. Any help would be greatly appreciated.
 
Back
Top