forked from nogweii/nginx-explorer
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnginx.conf
More file actions
43 lines (35 loc) · 665 Bytes
/
Copy pathnginx.conf
File metadata and controls
43 lines (35 loc) · 665 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
http {
include mime.types;
default_type application/octet-stream;
autoindex_format json;
autoindex_exact_size off;
autoindex_localtime on;
server {
listen 80;
#the root of your server
location /
{
root html;
index index.html;
}
#if path does not end with slash and is not a file
location ~ ^([^.\?]*[^/])$
{
try_files $uri @addslash;
}
#we add the slash
location @addslash
{
return 301 $uri/;
}
#visible path in uri
location /webfiles
{
try_files /_explorer/index.html /index.html;
}
#path for json requests
location /dir/webfiles
{
alias F:/webfiles;
autoindex on;
}