1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/selfoss_ynh.git synced 2024-09-03 20:16:21 +02:00

Fix Nginx conf

This commit is contained in:
Binnette 2022-04-06 23:26:50 +02:00
parent 619c43a0e5
commit 4a82ce6369

View file

@ -1,13 +1,8 @@
#sub_path_only rewrite ^__PATH__$ __PATH__/ permanent; #sub_path_only rewrite ^__PATH__$ __PATH__/ permanent;
location /selfoss { location /__PATH__ {
# Path to source # Path to source
root __FINALPATH__/; alias __FINALPATH__/;
access_log /var/log/nginx/rss.access.log;
error_log /var/log/nginx/rss.error.log;
#index index.php;
#try_files $uri /public/$uri /index.php;
location ~ [^/]\.php(/|$) { location ~ [^/]\.php(/|$) {
fastcgi_pass unix:/var/run/php/php__PHPVERSION__-fpm-__NAME__.sock; fastcgi_pass unix:/var/run/php/php__PHPVERSION__-fpm-__NAME__.sock;
@ -20,15 +15,15 @@ location /selfoss {
fastcgi_param SCRIPT_FILENAME $request_filename; fastcgi_param SCRIPT_FILENAME $request_filename;
} }
location ~ ^/selfoss/((favicons|thumbnails)/.+)$ { location ~ ^/__PATH__/((favicons|thumbnails)/.+)$ {
try_files /selfoss/data/$1 =404; try_files /__PATH__/data/$1 =404;
} }
location ~ ^/selfoss/$ { location ~ ^/__PATH__/$ {
index index.php; index index.php;
} }
location ~ ^/selfoss/(.+)$ { location ~ ^/__PATH__/(.+)$ {
try_files /selfoss/public/$1 /selfoss/index.php$is_args$args; try_files /__PATH__/public/$1 /__PATH__/index.php$is_args$args;
} }
} }