Hi,
I’m trying to configure nginx, but in the documentation it is only proposed a full configuration of nginx. I already have a lot of apps and configurations on my server, so I’d like to use only the minimal configuration, some lines to add to my already config file.
I have tried many thing but I can never go further than the homepage…
Here is my default conf https://pastebin.com/Fk70xtmJ
I tried to add :
location (/grav)/ {
try_files $uri $uri/ (/grav)/index.php?_url=$uri&$query_string;
}
From https://github.com/YunoHost-Apps/grav_ynh/blob/master/conf/nginx.conf I tried :
location /grav/ {
alias /path/to/my/grav/;
index index.php;
if (!-e $request_filename)
{
rewrite ^(.+)$ /grav/index.php?q=$1 last;
}
if ($scheme = http) {
rewrite ^ https://$server_name$request_uri? permanent;
}
From https://gist.github.com/DarrylDias/2a04dba9688e131eaced I tried :
location /mygrav {
index index.php;
if (!-e $request_filename){ rewrite ^(.*)$ /mygrav/$2 last; }
try_files $uri $uri/ /index.php?$args;
}
But nothing works…