2016-01-29 17:50:16 +01:00
|
|
|
server {
|
|
|
|
listen __PORT__;
|
|
|
|
server_name manager.__DNSDOMAIN__;
|
2017-02-28 21:40:29 +01:00
|
|
|
root __MANAGERSITEDIR__;
|
2016-01-29 17:50:16 +01:00
|
|
|
|
2017-02-22 22:48:52 +01:00
|
|
|
if ($uri !~ ^/(.*\.psgi|static|doc|fr-doc|lib|javascript|favicon)) {
|
2016-01-29 17:50:16 +01:00
|
|
|
rewrite ^/(.*)$ /manager.psgi/$1 break;
|
|
|
|
}
|
|
|
|
|
2017-02-22 22:48:52 +01:00
|
|
|
location ~ \.psgi(?:$|/) {
|
2016-01-29 17:50:16 +01:00
|
|
|
include /etc/nginx/fastcgi_params;
|
2016-02-15 22:12:56 +01:00
|
|
|
fastcgi_pass unix:__FASTCGISOCKDIR__/llng-fastcgi.sock;
|
2017-02-22 22:48:52 +01:00
|
|
|
fastcgi_param LLTYPE psgi;
|
2017-01-18 20:47:29 +01:00
|
|
|
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
|
2017-01-18 18:55:04 +01:00
|
|
|
fastcgi_split_path_info ^(.*\.psgi)(/.*)$;
|
2017-01-09 22:54:06 +01:00
|
|
|
fastcgi_param PATH_INFO $fastcgi_path_info;
|
2017-01-18 22:13:08 +01:00
|
|
|
add_header X-Content-Type-Options nosniff;
|
|
|
|
add_header X-XSS-Protection "1; mode=block";
|
2017-03-15 16:57:46 +01:00
|
|
|
add_header Content-Security-Policy "default-src 'self';frame-ancestors 'none';form-action 'self';img-src 'self' auth.example.com;";
|
2017-01-18 22:13:08 +01:00
|
|
|
add_header X-Frame-Options DENY;
|
|
|
|
# Uncomment this if you use https only
|
|
|
|
#add_header Strict-Transport-Security "15768000";
|
2016-01-29 17:50:16 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
location / {
|
2016-02-18 13:23:55 +01:00
|
|
|
index manager.psgi;
|
2016-02-11 10:36:12 +01:00
|
|
|
try_files $uri $uri/ =404;
|
2017-02-22 22:48:52 +01:00
|
|
|
allow 127.0.0.0/8;
|
|
|
|
deny all;
|
2016-01-29 17:50:16 +01:00
|
|
|
}
|
2016-02-16 12:19:32 +01:00
|
|
|
|
2016-02-21 09:29:19 +01:00
|
|
|
location /doc/ {
|
|
|
|
alias __DEFDOCDIR__;
|
2016-11-23 19:26:56 +01:00
|
|
|
index index.html start.html;
|
2016-02-21 09:29:19 +01:00
|
|
|
}
|
|
|
|
location /lib/ {
|
2017-01-18 22:13:08 +01:00
|
|
|
alias __DEFDOCDIR__pages/documentation/current/lib/;
|
2016-02-21 09:29:19 +01:00
|
|
|
}
|
|
|
|
location /fr-doc/ {
|
|
|
|
alias __FRDOCDIR__;
|
2016-11-23 19:26:56 +01:00
|
|
|
index index.html start.html;
|
2016-02-21 09:29:19 +01:00
|
|
|
}
|
2017-01-18 22:13:08 +01:00
|
|
|
location /static/ {
|
|
|
|
alias __MANAGERSTATICDIR__;
|
|
|
|
}
|
|
|
|
|
|
|
|
# DEBIAN
|
|
|
|
# If install was made with USEDEBIANLIBS (official releases), uncomment this
|
|
|
|
#location /javascript/ {
|
|
|
|
# alias /usr/share/javascript/;
|
|
|
|
#}
|
|
|
|
|
2016-01-29 17:50:16 +01:00
|
|
|
}
|