Webdav Setup
Table of Contents
1 Introduction
WebDAV is an extension of the HTTP protocol. It's mainly used for mapping cloud drives - map cloud storage as a network drive. It allows multiple users from multiple locations to work on a single file.
I use it to securely store my files and access them from anywhere. (e.g. keepass config file settings, notes to self, pdfs )
2 Setup
Nginx over HTTPS is assumed.
Create a directory in your web folder (e.g. /var/www/webdav)
Create a place to hold temp files (buffer for files in edit mode)
Create an htpasswd file
Edit your nginx file
root /var/www/webdav; location / { client_body_temp_path /var/www/webdav/temp; dav_methods PUT DELETE MKCOL COPY MOVE; dav_ext_methods PROPFIND OPTIONS; create_full_put_path on; dav_access user:rw group:rw; auth_basic "restricted"; auth_basic_user_file /usr/local/etc/nginx/.htpasswd; }