Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- FROM registry.exmoney.com/exmo/operations/base_images/debian9_base:latest
- ENV DOCKER_CACHE_CONTROL 1
- ENV DEBIAN_FRONTEND noninteractive
- ENV NGINX_VERSION "1.14.2"
- ENV NGINX_VTS_VERSION "0.1.18"
- RUN echo "deb-src http://nginx.org/packages/debian/ stretch nginx" >> /etc/apt/sources.list \
- && apt-get update \
- && apt-get install -y dpkg-dev curl nginx nginx-extras nginx-common \
- && mkdir -p /opt/rebuildnginx \
- && chmod 0777 /opt/rebuildnginx \
- && cd /opt/rebuildnginx \
- && su --preserve-environment -s /bin/bash -c "apt-get source nginx" _apt \
- && apt-get build-dep -y nginx=${NGINX_VERSION} \
- && cd /opt \
- && curl -sL https://github.com/vozlt/nginx-module-vts/archive/v${NGINX_VTS_VERSION}.tar.gz | tar -xz \
- && sed -i -r -e "s/\.\/configure(.*)/.\/configure\1 --add-module=\/opt\/nginx-module-vts-${NGINX_VTS_VERSION}/" /opt/rebuildnginx/nginx-${NGINX_VERSION}/debian/rules \
- && cd /opt/rebuildnginx/nginx-${NGINX_VERSION} \
- && dpkg-buildpackage -b \
- && cd /opt/rebuildnginx \
- && dpkg --install nginx_${NGINX_VERSION}-1~stretch_amd64.deb \
- && apt-get remove --purge -y dpkg-dev curl && apt-get -y --purge autoremove && rm -rf /var/lib/apt/lists/*
- CMD ["nginx", "-g", "daemon off;"]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement