diff --git a/swarm/stack/caddy/Caddyfile b/swarm/stack/caddy/Caddyfile index 30e91d8..baee66e 100644 --- a/swarm/stack/caddy/Caddyfile +++ b/swarm/stack/caddy/Caddyfile @@ -51,15 +51,23 @@ # Nextcloud AIO - Optimized for WebDAV and Folder Uploads cloud.netgrimoire.com { - # No CrowdSec here for now to prevent 404s on rapid-fire WebDAV requests + request_body { + max_size -1 + } + reverse_proxy http://nextcloud-aio-apache:11000 { header_up Host {host} header_up X-Real-IP {remote_host} header_up X-Forwarded-For {remote_host} - header_up X-Forwarded-Proto {scheme} + # Hardcoding https is essential for AIO behind a proxy + header_up X-Forwarded-Proto https + + # Essential for WebDAV folder operations + header_up Destination {http.request.header.Destination} + transport http { - response_header_timeout 300s + response_header_timeout 600s dial_timeout 30s } }