How to install Leantime on a Plesk Server

So I wanted to deploy Leantime on my Plesk (Onyx 17.8.11) server using Nginx and PHP 7.3.22, everything worked fine exept for the uri rewriting provided by the docs.

Long story short, with the fact that Plesk does not allow direct access to nginx.config’s (actually it does, but it’s not advised to do so) you can set this in the " Additional nginx directives" box (under the “Apache & nginx Settings” page of the domain) :

if ($ssl_protocol = "") {
	rewrite ^/(.*) https://$server_name/$1 permanent;
}
rewrite ^/resetPassword$ /index.php?resetPassword=true;
rewrite ^/resetPassword/([^/\.]+)/?$ /index.php?resetPassword=true&hash=$1;
rewrite ^/install$ /index.php?install=true;
rewrite ^/install/([^/\.]+)/?$ /index.php?install=true;
rewrite ^/update /index.php?update=true;
rewrite ^/update/([^/\.]+)/?$ /index.php?update=true;
rewrite ^/?$ /index.php?act=dashboard.show;
rewrite ^/([^/\.]+)/([^/\.]+)/?$ /index.php?act=$1.$2;
rewrite ^/([^/\.]+)/([^/\.]+)/([^/\.]+)/?$ /index.php?act=$1.$2&id=$3;

This should be enough to fix it.

I actually just saw the docs repo, made a pull request just to save time.

1 Like

Thank you. Appreciate the PR!