From 1409a26d56638cbca87aec016b7fdfe8e1b09a26 Mon Sep 17 00:00:00 2001 From: Yury Date: Tue, 11 Feb 2020 17:49:03 +0300 Subject: [PATCH] Dockerfile, readme update --- Dockerfile | 38 ++++++++++++++++++++++++++++++++++++++ README.md | 4 ++++ 2 files changed, 42 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..b82690e --- /dev/null +++ b/Dockerfile @@ -0,0 +1,38 @@ +FROM ubuntu:18.04 + +LABEL maintainer="Yury Muski " + +ENV NGINX_PATH /opt/nginx +ENV NGINX_VERSION 1.16.1 + +WORKDIR /opt + +RUN apt-get update && \ + apt-get install -y libpcre3 libpcre3-dev zlib1g-dev zlib1g golang-go build-essential git curl cmake; + +RUN curl -O https://nginx.org/download/nginx-$NGINX_VERSION.tar.gz && \ + tar xvzf nginx-$NGINX_VERSION.tar.gz && \ + git clone --recursive https://github.com/cloudflare/quiche && \ + cd nginx-$NGINX_VERSION && \ + patch -p01 < ../quiche/extras/nginx/nginx-1.16.patch && \ + curl https://sh.rustup.rs -sSf | sh -s -- -y -q && \ + export PATH="$HOME/.cargo/bin:$PATH" && \ + ./configure \ + --prefix=$NGINX_PATH \ + --with-http_ssl_module \ + --with-http_v2_module \ + --with-http_v3_module \ + --with-openssl=/opt/quiche/deps/boringssl \ + --with-quiche=/opt/quiche &&\ + make && \ + make install; + +RUN ln -sf /dev/stdout $NGINX_PATH/logs/access.log && \ + ln -sf /dev/stderr $NGINX_PATH/logs/error.log && \ + ln -sf $NGINX_PATH/sbin/nginx /usr/local/sbin/nginx + +EXPOSE 80 + +STOPSIGNAL SIGTERM + +CMD ["nginx", "-g", "daemon off;"] \ No newline at end of file diff --git a/README.md b/README.md index 8b070e4..4ed8833 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,6 @@ # nginx-http3 Nginx compiled with BoringSSL and quiche for HTTP3 support + +Image is super large ~2GB, recommed to use: + +https://github.com/RanadeepPolavarapu/docker-nginx-http3 \ No newline at end of file