4 ms·
Just did some quick research and it looks like you can serve pre-compressed static resources in Brotil. See the precompressed option of the file_server directiv
by anotherevan 4y ago
Just did some quick research and it looks like you can serve pre-compressed static resources in Brotil. See the precompressed option of the file_server directive[1].
The thinking seems to be due to how CPU intensive it is, Brotil is not favoured for on-the-fly compression[2].
If you're really desperate for it though, you could try [this extension][3].
[1] https://caddyserver.com/docs/caddyfile/directives/file_server https://caddyserver.com/docs/caddyfile/directives/file_serve...
[2] https://caddy.community/t/caddy-v2-brotli/8805 https://caddy.community/t/caddy-v2-brotli/8805
[3] https://github.com/ueffel/caddy-brotli https://github.com/ueffel/caddy-brotli
- jacooper 4y agoThe extension is not performance focused, so its slow. Other webservers support it, mainly Nginx. But since Caddy is written in go, they need a native go port which doesn't exist yet.
- anotherevan 4y ago> The extension is not performance focused, so its slow. Yeah, hence my "really desperate" qualifier. I probably should have been more explicit.