Skip to content

Commit

Permalink
Merge pull request heroku#11 from heroku/bf/add-zlib
Browse files Browse the repository at this point in the history
add zlib/gzip support
  • Loading branch information
beanieboi authored Sep 13, 2018
2 parents 1b19b7b + 5beaa03 commit 16db1c5
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 0 deletions.
Binary file modified bin/nginx-cedar-14
Binary file not shown.
Binary file modified bin/nginx-heroku-16
Binary file not shown.
Binary file modified bin/nginx-heroku-18
Binary file not shown.
7 changes: 7 additions & 0 deletions scripts/build_nginx
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,12 @@
NGINX_VERSION=${NGINX_VERSION-1.9.5}
PCRE_VERSION=${PCRE_VERSION-8.37}
HEADERS_MORE_VERSION=${HEADERS_MORE_VERSION-0.261}
ZLIB_VERSION=${ZLIB_VERSION-1.2.11}

nginx_tarball_url=http://nginx.org/download/nginx-${NGINX_VERSION}.tar.gz
pcre_tarball_url=http://iweb.dl.sourceforge.net/project/pcre/pcre/${PCRE_VERSION}/pcre-${PCRE_VERSION}.tar.bz2
headers_more_nginx_module_url=https://github.com/openresty/headers-more-nginx-module/archive/v${HEADERS_MORE_VERSION}.tar.gz
zlib_url=http://zlib.net/zlib-${ZLIB_VERSION}.tar.gz

temp_dir=$(mktemp -d /tmp/nginx.XXXXXXXXXX)

Expand All @@ -35,10 +37,15 @@ echo "Downloading $pcre_tarball_url"
echo "Downloading $headers_more_nginx_module_url"
(cd nginx-${NGINX_VERSION} && curl -L $headers_more_nginx_module_url | tar xvz )

echo "Downloading $zlib_url"
(cd nginx-${NGINX_VERSION} && curl -L $zlib_url | tar xvz )

(
cd nginx-${NGINX_VERSION}
./configure \
--with-pcre=pcre-${PCRE_VERSION} \
--with-zlib=zlib-${ZLIB_VERSION} \
--with-http_gzip_static_module \
--with-http_realip_module \
--prefix=/tmp/nginx \
--add-module=/${temp_dir}/nginx-${NGINX_VERSION}/headers-more-nginx-module-${HEADERS_MORE_VERSION}
Expand Down

0 comments on commit 16db1c5

Please sign in to comment.