• 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.

Issue Nginx url rewriting not working

capps

New Pleskian
Server operating system version
Alma Linux
Plesk version and microupdate number
Plesk Obsidian 18.0.70
I am trying to get the following rule to work for a domain:
Code:
try_files $uri $uri/ /index.php$is_args$query_string;

When i add that rule in Additional nginx directives only the homepage works. The other pages gives me Plesk 404.

But when I add the same code in /var/www/vhosts/system/domain.com/conf/nginx.conf under /
Code:
location / {
...
try_files $uri $uri/ /index.php$is_args$query_string;
}

Restart nginx, everything works fine.

But I will lose these setting the moment I update the PHP version for example.
So how can I het this to work in Additional nginx directives?
 
Did you wrap the directive rule in a location block too when adding to the Additional nginx directives in Plesk?
 
Back
Top