move text compression from Caddy to nginx for lower latency

Nginx is closer to the origin, so compressing there avoids an
extra hop. Removes the Caddy encode block for Nextcloud and adds
gzip in nginx with level 4 targeting text, CSS, JS, JSON, XML, SVG.
This commit is contained in:
2026-03-22 21:08:40 +01:00
parent d62b627093
commit a02f33e96e
2 changed files with 7 additions and 12 deletions

View File

@@ -9,18 +9,6 @@
}
nextcloud.t-gstone.de {
encode zstd gzip {
match {
header Content-Type text/*
header Content-Type application/javascript*
header Content-Type application/json*
header Content-Type application/xml*
header Content-Type application/rss*
header Content-Type application/atom*
header Content-Type image/svg*
}
}
reverse_proxy nextcloud-nginx:80
header Strict-Transport-Security "max-age=31536000; includeSubDomains; preload"