heroku-buildpack-php
heroku-buildpack-php copied to clipboard
Brotli support
Support of Brotli compression on apache and nginx could be nice to have along Gzip and Deflate.
https://httpd.apache.org/docs/2.4/fr/mod/mod_brotli.html https://github.com/google/ngx_brotli
Serving brotli compressed files reduce transfer size for HTML, CSS, JS and SVG files better than with GZIP, but not JPG, PNG, WebP, GIFs etc. (binary files). So both (GZIP and Brotli) should be available.
Would be very nice to use Brotli
On heroku-22, mod_brotli
should be available.
In a custom HTTPD config include (the -C
thing), could you try the following?
LoadModule brotli_module libexec/mod_brotli.so
@dzuelke thanks, and on NGINX? (using NGINX in all my projects only)
Thing there is that it's a commercial Nginx Plus module, or that third-party module maintained by Google. So far, we haven't enabled third party modules for Nginx, since they sometimes get abandoned by the maintainers, and then it would be up to us to figure stuff out. But I'll think about it.
However, there's a new buildpack structure coming with the switch to CNBs, where new specialized web server buildpacks for Nginx and HTTPD will likely improve this, and one thing on the features wishlist is the ability to easily-ish BYO modules.
(Specifically, that Google-maintained module has a bunch of open, unaddressed issues, and no tagged releases).
Thanks for explaining