diff --git a/docker/Dockerfile b/docker/Dockerfile index b5595c7..0d9c2d2 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -20,7 +20,8 @@ RUN apt-get update \ wget \ zlib1g-dev \ git \ - libmaxminddb-dev + libmaxminddb-dev \ + libbrotli-dev # Lua build COPY ./scripts/build-lua /tmp/build-lua @@ -63,6 +64,7 @@ RUN apt-get update \ xz-utils \ libmaxminddb-dev \ moreutils \ + libbrotli1 \ && apt-get clean \ && rm -rf /var/lib/apt/lists/* \ && rm -rf /var/cache/* /var/log/* /tmp/* /var/lib/dpkg/status-old diff --git a/scripts/build-openresty b/scripts/build-openresty index 9f3a1bb..7186c8f 100755 --- a/scripts/build-openresty +++ b/scripts/build-openresty @@ -14,6 +14,8 @@ tar -xzf openresty-${OPENRESTY_VERSION}.tar.gz mv /tmp/openresty-${OPENRESTY_VERSION} /tmp/openresty git clone https://github.com/leev/ngx_http_geoip2_module.git mv /tmp/ngx_http_geoip2_module /tmp/openresty/ngx_http_geoip2_module +git clone --recursive https://github.com/google/ngx_brotli.git +mv /tmp/ngx_brotli /tmp/openresty/ngx_brotli cd /tmp/openresty ./configure \ @@ -55,7 +57,8 @@ cd /tmp/openresty --with-stream_realip_module \ --with-stream_ssl_module \ --with-stream_ssl_preread_module \ - --add-dynamic-module=/tmp/openresty/ngx_http_geoip2_module + --add-dynamic-module=/tmp/openresty/ngx_http_geoip2_module \ + --add-module=/tmp/openresty/ngx_brotli make -j2