2017-04-23 17:29:55 +02:00
|
|
|
location YNH_WWW_PATH/ {
|
|
|
|
alias YNH_WWW_ALIAS;
|
2016-08-21 01:03:46 +02:00
|
|
|
index index.php;
|
|
|
|
try_files $uri $uri/ index.php?$args;
|
2017-04-24 16:04:55 +02:00
|
|
|
|
2016-08-21 01:03:46 +02:00
|
|
|
location ~ [^/]\.php(/|$) {
|
|
|
|
fastcgi_split_path_info ^(.+?\.php)(/.*)$;
|
2017-04-24 16:04:55 +02:00
|
|
|
fastcgi_pass unix:/var/run/php5-fpm-YNH_WWW_APP.sock;
|
2016-08-21 01:03:46 +02:00
|
|
|
fastcgi_index index.php;
|
|
|
|
include fastcgi_params;
|
|
|
|
fastcgi_param REMOTE_USER $remote_user;
|
|
|
|
fastcgi_param PATH_INFO $fastcgi_path_info;
|
|
|
|
fastcgi_param SCRIPT_FILENAME $request_filename;
|
|
|
|
}
|
|
|
|
|
2017-04-23 17:29:55 +02:00
|
|
|
location ~ ^YNH_WWW_PATH/(?:ico|css|js|gif|jpe?g|png|ttf|woff)$ {
|
2016-08-21 01:03:46 +02:00
|
|
|
access_log off;
|
|
|
|
expires 30d;
|
|
|
|
add_header Pragma public;
|
|
|
|
add_header Cache-Control "public, mustrevalidate, proxy-revalidate";
|
|
|
|
}
|
|
|
|
|
2017-04-23 17:29:55 +02:00
|
|
|
location = YNH_WWW_PATH/protected {
|
2016-08-21 01:03:46 +02:00
|
|
|
deny all;
|
|
|
|
}
|
|
|
|
|
2017-04-23 17:29:55 +02:00
|
|
|
location = YNH_WWW_PATH/uploads/file {
|
2016-08-21 01:03:46 +02:00
|
|
|
deny all;
|
|
|
|
}
|
|
|
|
|
|
|
|
# Include SSOWAT user panel.
|
|
|
|
include conf.d/yunohost_panel.conf.inc;
|
|
|
|
}
|