Switch Caddy from gzip to brotli

This commit is contained in:
sunstep 2024-09-27 10:06:38 +02:00 committed by GitHub
parent 4a35c0dd61
commit f0ddbecd2b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -145,14 +145,17 @@ Lastly, edit your Caddy config as needed:
<YOUR FQDN HERE (ex. dawarich.example.com)> {
reverse_proxy dawarich_app:3000
encode gzip {
encode brotli {
match {
content_type application/json
content_type text/css text/plain text/xml text/x-component text/javascript application/x-javascript application/javascript application/json application/manifest+json application/vnd.api+json application/xml application/xhtml+xml application/rss+xml application/atom+xml application/vnd.ms-fontobject application/x-font-ttf application/x-font-opentype application/x-font-truetype image/svg+xml image/x-icon image/vnd.microsoft.icon font/ttf font/eot font/otf font/opentype
}
}
}
```
At your FQDN, do not include < >
---
Please note that the above configurations are just examples and that they contain the minimum configuration needed to make the reverse proxy work properly. Feel free to adjust the configuration to your own needs.