Sign inSign up

anroe/nginx-brotli

By anroe

•Updated almost 4 years ago

Nginx with Brotli as dynamic module based on official Nginx images (Alpine and Debian)

Image
0

620

anroe/nginx-brotli repository overview

⁠Table of contents

⁠Tags

Tag syntax : {nginx-tag}-{module_name}-{module_version}

⁠How to use this image

⁠How to use it with your own image

You can use the Brotli module compiled in this image in your own image.

At the beginning of nginx.conf :

load_module /usr/lib/nginx/modules/ngx_http_brotli_filter_module.so;
load_module /usr/lib/nginx/modules/ngx_http_brotli_static_module.so;

In http, server or location block :

brotli on;
brotli_comp_level 6;
brotli_static on;
brotli_types application/atom+xml application/javascript application/json application/rss+xml application/vnd.ms-fontobject application/x-font-opentype application/x-font-truetype application/x-font-ttf application/x-javascript application/xhtml+xml application/xml font/eot font/opentype font/otf font/truetype image/svg+xml image/vnd.microsoft.icon image/x-icon image/x-win-bitmap text/css text/javascript text/plain text/xml;

⁠Debian

In your Dockerfile :

COPY --from=anroe/nginx-brotli:1.19.2-brotli-v1.0.0rc /usr/lib/nginx/modules/ngx_http_brotli_static_module.so /usr/lib/nginx/modules/ngx_http_brotli_static_module.so
COPY --from=anroe/nginx-brotli:1.19.2-brotli-v1.0.0rc /usr/lib/nginx/modules/ngx_http_brotli_filter_module.so /usr/lib/nginx/modules/ngx_http_brotli_filter_module.so

⁠Alpine

In your Dockerfile :

COPY --from=anroe/nginx-brotli:1.19.2-alpine-brotli-v1.0.0rc /usr/lib/nginx/modules/ngx_http_brotli_static_module.so /usr/lib/nginx/modules/ngx_http_brotli_static_module.so
COPY --from=anroe/nginx-brotli:1.19.2-alpine-brotli-v1.0.0rc /usr/lib/nginx/modules/ngx_http_brotli_filter_module.so /usr/lib/nginx/modules/ngx_http_brotli_filter_module.so

⁠Brotli nginx module

https://github.com/google/ngx_brotli⁠

⁠Other nginx modules

Tag summary

Content type

Image

Digest

Size

55.6 MB

Last updated

about 6 years ago

docker pull anroe/nginx-brotli