using alias in nginx config for /files to save headaches

This commit is contained in:
Mohammad Naghavi 2016-02-15 11:32:31 +01:00
parent 79baf80b30
commit c2b2e7db03

View file

@ -5,12 +5,8 @@ server {
root /opt/www/;
index index.html index.htm;
location ~* (/javadoc)|(/tests) {
autoindex off;
}
location /files/ {
root /opt/www/; # will at the end serve /opt/www/files/
alias /opt/www/files/;
index ___i; # we really need no index here, just listing files
autoindex on;