Pierre-Olivier Mercier
63a55a8a0b
As a consequence, we can rely on them to display a correct information on user pages through angularJS.
64 lines
1.4 KiB
Plaintext
64 lines
1.4 KiB
Plaintext
server {
|
|
listen 80 default_server;
|
|
listen [::]:80 default_server;
|
|
|
|
server_name fic.srs.epita.fr;
|
|
|
|
access_log /var/log/nginx/fic2016.access_log main;
|
|
error_log /var/log/nginx/fic2016.error_log info;
|
|
|
|
root /srv/www/fic2016-static/;
|
|
|
|
error_page 403 404 /e404.html;
|
|
error_page 413 404 /e413.html;
|
|
error_page 500 502 504 /e500.html;
|
|
|
|
location /.htaccess {
|
|
return 404;
|
|
}
|
|
location /chbase.sh {
|
|
return 404;
|
|
}
|
|
|
|
location ~ ^/[0-9] {
|
|
rewrite ^/.*$ /index.html;
|
|
}
|
|
|
|
location /edit {
|
|
rewrite ^/.*$ /index.html;
|
|
}
|
|
|
|
location /rank {
|
|
rewrite ^/.*$ /index.html;
|
|
}
|
|
|
|
location /tags/ {
|
|
rewrite ^/.*$ /index.html;
|
|
}
|
|
|
|
location = /welcome.html {
|
|
internal;
|
|
if ($http_accept ~ "^application/json") {
|
|
rewrite ^/(.*).html$ /$1.json;
|
|
}
|
|
}
|
|
location = /e404.html {
|
|
internal;
|
|
if ($http_accept ~ "^application/json") {
|
|
rewrite ^/(.*).html$ /$1.json;
|
|
}
|
|
}
|
|
location = /e413.html {
|
|
internal;
|
|
if ($http_accept ~ "^application/json") {
|
|
rewrite ^/(.*).html$ /$1.json;
|
|
}
|
|
}
|
|
location = /e500.html {
|
|
internal;
|
|
if ($http_accept ~ "^application/json") {
|
|
rewrite ^/(.*).html$ /$1.json;
|
|
}
|
|
}
|
|
}
|