From 9e070a131868150f338a959135fc969bac8e51cb Mon Sep 17 00:00:00 2001 From: yurymuski Date: Sun, 3 Sep 2023 02:15:48 +0400 Subject: [PATCH] version bump --- .github/workflows/main.yml | 38 ++++++++++++++++++++++++++++++++++++++ Dockerfile | 8 ++++---- README.md | 4 ++-- example.nginx.conf | 2 +- 4 files changed, 45 insertions(+), 7 deletions(-) create mode 100644 .github/workflows/main.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..5c845d4 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,38 @@ +name: ci + +on: + push: + branches: + - master + paths-ignore: + - '**/README.md' + tags: + - '*' + +jobs: + + build-and-push: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + + - name: Inject slug/short variables + uses: rlespinasse/github-slug-action@v4.x + + - name: Login to Docker Hub + uses: docker/login-action@v2 + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + + - name: Build and push + uses: docker/build-push-action@v4 + with: + push: true + tags: | + ${{ secrets.DOCKERHUB_USERNAME }}/${{ env.GITHUB_REPOSITORY_NAME_PART }}:${{ env.GITHUB_REF_SLUG }} + ${{ secrets.DOCKERHUB_USERNAME }}/${{ env.GITHUB_REPOSITORY_NAME_PART }}:latest diff --git a/Dockerfile b/Dockerfile index e6b850e..27b68d1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,11 +1,11 @@ -FROM ubuntu:20.04 AS builder +FROM debian:12 AS builder LABEL maintainer="Yury Muski " ENV NGINX_PATH /etc/nginx ENV NGINX_VERSION 1.19.6 -ENV QUICHE_VERSION 0.9.0 +ENV QUICHE_VERSION 0.18.0 WORKDIR /opt @@ -17,7 +17,7 @@ RUN curl -O https://nginx.org/download/nginx-$NGINX_VERSION.tar.gz && \ git clone --branch $QUICHE_VERSION --recursive https://github.com/cloudflare/quiche && \ git clone --recursive https://github.com/google/ngx_brotli.git && \ cd nginx-$NGINX_VERSION && \ - patch -p01 < ../quiche/extras/nginx/nginx-1.16.patch && \ + patch -p01 < ../quiche/nginx/nginx-1.16.patch && \ curl https://sh.rustup.rs -sSf | sh -s -- -y -q && \ export PATH="$HOME/.cargo/bin:$PATH" && \ ./configure \ @@ -68,7 +68,7 @@ RUN curl -O https://nginx.org/download/nginx-$NGINX_VERSION.tar.gz && \ make && \ make install; -FROM ubuntu:20.04 +FROM debian:12-slim COPY --from=builder /usr/sbin/nginx /usr/sbin/ COPY --from=builder /etc/nginx/ /etc/nginx/ diff --git a/README.md b/README.md index 385aedd..1bd16e5 100644 --- a/README.md +++ b/README.md @@ -4,11 +4,11 @@ Nginx compiled with *BoringSSL* and *quiche* for *HTTP3* support, *Brotli* suppo ## version nginx version: nginx/1.19.6 (quiche-ad9d933) -quiche 0.9.0 +quiche 0.18.0 Based on ubuntu:20.04, size 109MB -Link for [quiche + nginx manual](https://github.com/cloudflare/quiche/tree/master/extras/nginx) +Link for [quiche + nginx manual](https://github.com/cloudflare/quiche/tree/master/nginx) ### usage - get certs from certbot in /etc/letsencrypt/ diff --git a/example.nginx.conf b/example.nginx.conf index 320b4b1..9ced9a4 100644 --- a/example.nginx.conf +++ b/example.nginx.conf @@ -62,7 +62,7 @@ http { return 200 "http3 on $hostname"; add_header Content-Type text/plain; # Add Alt-Svc header to negotiate HTTP/3. - add_header alt-svc 'h3-27=":443"; ma=86400, h3-28=":443"; ma=86400, h3-29=":443"; ma=86400, h3=":443"; ma=86400'; + add_header alt-svc 'h3=":443"; ma=86400'; } }