forked from duxlong/webdav
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathnginx.conf
40 lines (28 loc) · 905 Bytes
/
nginx.conf
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
# 修改 worker 进程的 user,设置错误会出现权限报错 "Permission denied"
user root;
worker_processes 1;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
server {
listen 80;
# 设置日志
access_log /dev/stdout;
error_log /dev/stdout info;
# MAX size of uploaded file, 0 mean unlimited
client_max_body_size 0;
location / {
root /data;
autoindex on;
create_full_put_path on;
dav_methods PUT DELETE MKCOL COPY MOVE;
dav_ext_methods PROPFIND OPTIONS;
dav_access user:rw group:rw all:r;
auth_basic "Restricted";
auth_basic_user_file /opt/nginx/conf/htpasswd;
}
}
}