server {
    listen 80 default_server;
    listen [::]:80 default_server;

    index index.html index.htm index.nginx-debian.html;

    server_name _;

    location / {
        root /var/www/html/;
        try_files $uri $uri/ =404;
    }

    location /upload {
        alias /var/www/html/upload/;
        dav_methods PUT;
        create_full_put_path on;
        dav_access user:rw group:r all:r;
    }
}