summaryrefslogtreecommitdiff
path: root/custom/ymir-nginx.nix
diff options
context:
space:
mode:
Diffstat (limited to 'custom/ymir-nginx.nix')
-rw-r--r--custom/ymir-nginx.nix7
1 files changed, 5 insertions, 2 deletions
diff --git a/custom/ymir-nginx.nix b/custom/ymir-nginx.nix
index ca14b8e8..9d02460d 100644
--- a/custom/ymir-nginx.nix
+++ b/custom/ymir-nginx.nix
@@ -186,10 +186,13 @@ in {
186 server { 186 server {
187 listen *:80; 187 listen *:80;
188 listen [::]:80; 188 listen [::]:80;
189
190 server_name ~^webdav\.(yggdrasil\.li|141\.li|praseodym\.org)$; 189 server_name ~^webdav\.(yggdrasil\.li|141\.li|praseodym\.org)$;
191 190
192 include ${acme}; 191 include ${acme};
192
193 location / {
194 return 301 https://$host$request_uri;
195 }
193 } 196 }
194 197
195 server { 198 server {
@@ -202,7 +205,7 @@ in {
202 alias /srv/www/webdav/$1$2; 205 alias /srv/www/webdav/$1$2;
203 autoindex on; 206 autoindex on;
204 207
205 auth_basic "WebDAV user directory of $1"; 208 auth_basic "WebDAV directory $1";
206 auth_basic_user_file /srv/www/webdav/$1.htpasswd; 209 auth_basic_user_file /srv/www/webdav/$1.htpasswd;
207 210
208 client_body_temp_path /tmp/webdav.$1; 211 client_body_temp_path /tmp/webdav.$1;