26 lines
766 B
Nginx Configuration File
Executable file
26 lines
766 B
Nginx Configuration File
Executable file
#sub_path_only rewrite ^__PATH__$ __PATH__/ permanent;
|
|
location __PATH__/ {
|
|
|
|
# Path to source
|
|
alias __INSTALL_DIR__/;
|
|
|
|
index index.php;
|
|
|
|
# Chrooted PHP-FPM
|
|
location __PATH__/index.php {
|
|
alias /;
|
|
fastcgi_pass unix:/var/run/php/php__PHPVERSION__-fpm-__NAME__.sock;
|
|
fastcgi_index index.php;
|
|
fastcgi_split_path_info ^(.+?\.php)(/.*)$;
|
|
fastcgi_param PATH_INFO $fastcgi_path_info;
|
|
fastcgi_param SCRIPT_FILENAME /index.php;
|
|
include fastcgi_params;
|
|
}
|
|
|
|
# Security related headers
|
|
more_set_headers "Referrer-Policy: no-referrer";
|
|
more_set_headers "Content-Security-Policy: default-src 'none'; style-src 'self'; img-src 'self' data:; frame-ancestors 'none'; form-action 'self';";
|
|
|
|
# Include SSOWAT user panel.
|
|
include conf.d/yunohost_panel.conf.inc;
|
|
}
|