.mine
This document describes installation and minimum configuration of Nginx on Debian server for HLS Webdav publication.
apt-get install nginx nginx-extras
server {
listen 82 default_server;
listen [::]:82 default_server;
....
}
mkdir /var/mountdav
mkdir /var/mountdav/webdav1
chown www-data -R /var/mountdav/webdav1
server { .... location /webdav1/ { root /var/mountdav/; client_body_temp_path /var/mountdav/webdav1/temp; dav_methods PUT DELETE MKCOL COPY MOVE; dav_ext_methods PROPFIND OPTIONS; create_full_put_path on; dav_access user:rw group:rw all:rw; autoindex on; #below you can specify the access restrictions. In this case, only people on the 10.3.X.Y/16 network #can write/delete/etc. Everyone else can view. limit_except GET PROPFIND OPTIONS{ allow 10.3.0.0/16; deny all; } allow all; } }
/etc/init.d/nginx restart
server { .... location /webdav_restricted/ { root /var/mountdav; client_body_temp_path /var/mountdav/webdav_restricted/temp; dav_methods PUT DELETE MKCOL COPY MOVE; dav_ext_methods PROPFIND OPTIONS; create_full_put_path on; dav_access user:rw group:rw all:rw; autoindex on; auth_basic "restricted"; auth_basic_user_file /etc/nginx/htpasswd; } }
mkdir /var/mountdav
mkdir /var/mountdav/webdav_restricted
chown www-data /var/mountdav/webdav_restricted
apt-get install apache2-utils
htpasswd -c /etc/nginx/htpasswd exampleuser
/etc/init.d/nginx restart
This document describes installation and minimum configuration of Nginx on Debian server for HLS Webdav publication.
apt-get install nginx nginx-extras
server {
listen 82 default_server;
listen [::]:82 default_server;
....
}
mkdir /var/mountdav
mkdir /var/mountdav/webdav1
chown www-data -R /var/mountdav/webdav1
server { .... location /webdav1/ { root /var/mountdav/; client_body_temp_path /var/mountdav/webdav1/temp; dav_methods PUT DELETE MKCOL COPY MOVE; dav_ext_methods PROPFIND OPTIONS; create_full_put_path on; dav_access user:rw group:rw all:rw; autoindex on; client_max_body_size 0; #below you can specify the access restrictions. In this case, only people on the 10.3.X.Y/16 network #can write/delete/etc. Everyone else can view. limit_except GET PROPFIND OPTIONS{ allow 10.3.0.0/16; deny all; } allow all; } }
/etc/init.d/nginx restart
server { .... location /webdav_restricted/ { root /var/mountdav; client_body_temp_path /var/mountdav/webdav_restricted/temp; dav_methods PUT DELETE MKCOL COPY MOVE; dav_ext_methods PROPFIND OPTIONS; create_full_put_path on; dav_access user:rw group:rw all:rw; autoindex on; client_max_body_size 0; auth_basic "restricted"; auth_basic_user_file /etc/nginx/htpasswd; } }
mkdir /var/mountdav
mkdir /var/mountdav/webdav_restricted
chown www-data /var/mountdav/webdav_restricted
apt-get install apache2-utils
htpasswd -c /etc/nginx/htpasswd exampleuser
/etc/init.d/nginx restart