From ea8b193858dc37b0dc1ea35f45b27bc41a887b74 Mon Sep 17 00:00:00 2001 From: thelamer Date: Sat, 23 Jan 2021 15:13:00 -0800 Subject: [PATCH 1/5] Rebasing to Alpine 3.13 --- Dockerfile | 2 +- Dockerfile.aarch64 | 2 +- Dockerfile.armhf | 2 +- readme-vars.yml | 1 + 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 1e2cd68..261be5a 100755 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM ghcr.io/linuxserver/baseimage-alpine-nginx:3.12 +FROM ghcr.io/linuxserver/baseimage-alpine-nginx:3.13 # set version label ARG BUILD_DATE diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index cfc1a83..b9250fc 100755 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -1,4 +1,4 @@ -FROM ghcr.io/linuxserver/baseimage-alpine-nginx:arm64v8-3.12 +FROM ghcr.io/linuxserver/baseimage-alpine-nginx:arm64v8-3.13 # set version label ARG BUILD_DATE diff --git a/Dockerfile.armhf b/Dockerfile.armhf index 0460d43..2df01ab 100755 --- a/Dockerfile.armhf +++ b/Dockerfile.armhf @@ -1,4 +1,4 @@ -FROM ghcr.io/linuxserver/baseimage-alpine-nginx:arm32v7-3.12 +FROM ghcr.io/linuxserver/baseimage-alpine-nginx:arm32v7-3.13 # set version label ARG BUILD_DATE diff --git a/readme-vars.yml b/readme-vars.yml index 4ce2d49..3456072 100755 --- a/readme-vars.yml +++ b/readme-vars.yml @@ -151,6 +151,7 @@ app_setup_nginx_reverse_proxy_block: "" # changelog changelogs: + - { date: "23.01.21:", desc: "Rebasing to alpine 3.13." } - { date: "20.01.21:", desc: "Add check for ZeroSSL EAB retrieval." } - { date: "08.01.21:", desc: "Add support for getting certs from [ZeroSSL](https://zerossl.com/) via optional `CERTPROVIDER` env var. Update aliyun, domeneshop, inxw and transip dns plugins with the new plugin names. Hide `donoteditthisfile.conf` because users were editing it despite its name. Suppress harmless error when no proxy confs are enabled." } - { date: "03.01.21:", desc: "[Existing users should update:](https://github.com/linuxserver/docker-swag/blob/master/README.md#updating-configs) /config/nginx/site-confs/default - Add helper pages to aid troubleshooting" } From de98308c7054dd8ab293af31668c6597b94dfff3 Mon Sep 17 00:00:00 2001 From: aptalca Date: Mon, 8 Feb 2021 16:06:12 -0500 Subject: [PATCH 2/5] add cargo/rust to fix cryptography builds --- Dockerfile | 1 + Dockerfile.aarch64 | 1 + Dockerfile.armhf | 1 + 3 files changed, 3 insertions(+) diff --git a/Dockerfile b/Dockerfile index 261be5a..6e31f57 100755 --- a/Dockerfile +++ b/Dockerfile @@ -14,6 +14,7 @@ ENV S6_BEHAVIOUR_IF_STAGE2_FAILS=2 RUN \ echo "**** install build packages ****" && \ apk add --no-cache --virtual=build-dependencies \ + cargo \ g++ \ gcc \ libffi-dev \ diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index b9250fc..eb2d58f 100755 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -14,6 +14,7 @@ ENV S6_BEHAVIOUR_IF_STAGE2_FAILS=2 RUN \ echo "**** install build packages ****" && \ apk add --no-cache --virtual=build-dependencies \ + cargo \ g++ \ gcc \ libffi-dev \ diff --git a/Dockerfile.armhf b/Dockerfile.armhf index 2df01ab..c45ced2 100755 --- a/Dockerfile.armhf +++ b/Dockerfile.armhf @@ -14,6 +14,7 @@ ENV S6_BEHAVIOUR_IF_STAGE2_FAILS=2 RUN \ echo "**** install build packages ****" && \ apk add --no-cache --virtual=build-dependencies \ + cargo \ g++ \ gcc \ libffi-dev \ From 479ee5eac1b23da26881cdc78918b7691bd5e2b2 Mon Sep 17 00:00:00 2001 From: aptalca Date: Tue, 9 Feb 2021 10:50:54 -0500 Subject: [PATCH 3/5] add brotli and dav-ext, remove lua --- Dockerfile | 4 ++-- Dockerfile.aarch64 | 4 ++-- Dockerfile.armhf | 4 ++-- README.md | 1 + readme-vars.yml | 2 +- root/defaults/nginx.conf | 4 ++-- root/etc/cont-init.d/50-config | 6 ++++++ 7 files changed, 16 insertions(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index 18d5424..4928ee2 100755 --- a/Dockerfile +++ b/Dockerfile @@ -27,13 +27,13 @@ RUN \ gnupg \ memcached \ nginx \ + nginx-mod-http-brotli \ + nginx-mod-http-dav-ext \ nginx-mod-http-echo \ nginx-mod-http-fancyindex \ nginx-mod-http-geoip2 \ nginx-mod-http-headers-more \ nginx-mod-http-image-filter \ - nginx-mod-http-lua \ - nginx-mod-http-lua-upstream \ nginx-mod-http-nchan \ nginx-mod-http-perl \ nginx-mod-http-redis2 \ diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index e77a0e3..e57d2b2 100755 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -27,13 +27,13 @@ RUN \ gnupg \ memcached \ nginx \ + nginx-mod-http-brotli \ + nginx-mod-http-dav-ext \ nginx-mod-http-echo \ nginx-mod-http-fancyindex \ nginx-mod-http-geoip2 \ nginx-mod-http-headers-more \ nginx-mod-http-image-filter \ - nginx-mod-http-lua \ - nginx-mod-http-lua-upstream \ nginx-mod-http-nchan \ nginx-mod-http-perl \ nginx-mod-http-redis2 \ diff --git a/Dockerfile.armhf b/Dockerfile.armhf index 44c4cb6..681d520 100755 --- a/Dockerfile.armhf +++ b/Dockerfile.armhf @@ -27,13 +27,13 @@ RUN \ gnupg \ memcached \ nginx \ + nginx-mod-http-brotli \ + nginx-mod-http-dav-ext \ nginx-mod-http-echo \ nginx-mod-http-fancyindex \ nginx-mod-http-geoip2 \ nginx-mod-http-headers-more \ nginx-mod-http-image-filter \ - nginx-mod-http-lua \ - nginx-mod-http-lua-upstream \ nginx-mod-http-nchan \ nginx-mod-http-perl \ nginx-mod-http-redis2 \ diff --git a/README.md b/README.md index bb173ee..5ed9133 100644 --- a/README.md +++ b/README.md @@ -326,6 +326,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64 ## Versions +* **09.02.21:** - Rebasing to alpine 3.13. Add nginx mods brotli and dav-ext. Remove nginx mods lua and lua-upstream (due to regression over the last couple of years). * **26.01.21:** - Add support for hetzner dns validation. * **20.01.21:** - Add check for ZeroSSL EAB retrieval. * **08.01.21:** - Add support for getting certs from [ZeroSSL](https://zerossl.com/) via optional `CERTPROVIDER` env var. Update aliyun, domeneshop, inxw and transip dns plugins with the new plugin names. Hide `donoteditthisfile.conf` because users were editing it despite its name. Suppress harmless error when no proxy confs are enabled. diff --git a/readme-vars.yml b/readme-vars.yml index 4e7415e..777ff5e 100755 --- a/readme-vars.yml +++ b/readme-vars.yml @@ -151,7 +151,7 @@ app_setup_nginx_reverse_proxy_block: "" # changelog changelogs: - - { date: "08.02.21:", desc: "Rebasing to alpine 3.13." } + - { date: "09.02.21:", desc: "Rebasing to alpine 3.13. Add nginx mods brotli and dav-ext. Remove nginx mods lua and lua-upstream (due to regression over the last couple of years)." } - { date: "26.01.21:", desc: "Add support for hetzner dns validation." } - { date: "20.01.21:", desc: "Add check for ZeroSSL EAB retrieval." } - { date: "08.01.21:", desc: "Add support for getting certs from [ZeroSSL](https://zerossl.com/) via optional `CERTPROVIDER` env var. Update aliyun, domeneshop, inxw and transip dns plugins with the new plugin names. Hide `donoteditthisfile.conf` because users were editing it despite its name. Suppress harmless error when no proxy confs are enabled." } diff --git a/root/defaults/nginx.conf b/root/defaults/nginx.conf index 4192e9e..a47a405 100644 --- a/root/defaults/nginx.conf +++ b/root/defaults/nginx.conf @@ -1,4 +1,4 @@ -## Version 2020/10/04 - Changelog: https://github.com/linuxserver/docker-swag/commits/master/root/defaults/nginx.conf +## Version 2021/02/09 - Changelog: https://github.com/linuxserver/docker-swag/commits/master/root/defaults/nginx.conf user abc; worker_processes 4; @@ -85,7 +85,7 @@ http { ## include /etc/nginx/conf.d/*.conf; include /config/nginx/site-confs/*; - lua_load_resty_core off; + #Removed lua. Do not remove this comment ## # Geoip2 config diff --git a/root/etc/cont-init.d/50-config b/root/etc/cont-init.d/50-config index 42cdd77..6c998fc 100644 --- a/root/etc/cont-init.d/50-config +++ b/root/etc/cont-init.d/50-config @@ -81,6 +81,12 @@ cp /config/fail2ban/jail.local /etc/fail2ban/jail.local [[ ! -f /config/www/502.html ]] && cp /defaults/502.html /config/www/502.html +# remove lua bits from nginx.conf if not done before +if ! grep -q '#Removed lua' nginx.conf; then + echo "Removing lua specific info from nginx.conf" + sed -i 's|\tlua_load_resty_core off;|\t#Removed lua. Do not remove this comment|g' nginx.conf +fi + # copy pre-generated dhparams or generate if needed [[ ! -f /config/nginx/dhparams.pem ]] && \ cp /defaults/dhparams.pem /config/nginx/dhparams.pem From 9074cf2d44cce821c3d14569b958dd01fc47d023 Mon Sep 17 00:00:00 2001 From: aptalca Date: Tue, 9 Feb 2021 11:23:08 -0500 Subject: [PATCH 4/5] I like to copy pasta --- root/etc/cont-init.d/50-config | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/root/etc/cont-init.d/50-config b/root/etc/cont-init.d/50-config index 6c998fc..8400d00 100644 --- a/root/etc/cont-init.d/50-config +++ b/root/etc/cont-init.d/50-config @@ -82,9 +82,9 @@ cp /config/fail2ban/jail.local /etc/fail2ban/jail.local cp /defaults/502.html /config/www/502.html # remove lua bits from nginx.conf if not done before -if ! grep -q '#Removed lua' nginx.conf; then +if ! grep -q '#Removed lua' /config/nginx/nginx.conf; then echo "Removing lua specific info from nginx.conf" - sed -i 's|\tlua_load_resty_core off;|\t#Removed lua. Do not remove this comment|g' nginx.conf + sed -i 's|\tlua_load_resty_core off;|\t#Removed lua. Do not remove this comment|g' /config/nginx/nginx.conf fi # copy pre-generated dhparams or generate if needed From e7b58163041313b40ba25cc30a0307b5ee960e59 Mon Sep 17 00:00:00 2001 From: aptalca Date: Wed, 10 Feb 2021 09:52:09 -0500 Subject: [PATCH 5/5] enable rust for py crypto --- Dockerfile | 2 +- Dockerfile.aarch64 | 2 +- Dockerfile.armhf | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index afd50e8..4928ee2 100755 --- a/Dockerfile +++ b/Dockerfile @@ -9,7 +9,7 @@ LABEL maintainer="aptalca" # environment settings ENV DHLEVEL=2048 ONLY_SUBDOMAINS=false AWS_CONFIG_FILE=/config/dns-conf/route53.ini -ENV S6_BEHAVIOUR_IF_STAGE2_FAILS=2 CRYPTOGRAPHY_DONT_BUILD_RUST=true +ENV S6_BEHAVIOUR_IF_STAGE2_FAILS=2 RUN \ echo "**** install build packages ****" && \ diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index 5aa488e..e57d2b2 100755 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -9,7 +9,7 @@ LABEL maintainer="aptalca" # environment settings ENV DHLEVEL=2048 ONLY_SUBDOMAINS=false AWS_CONFIG_FILE=/config/dns-conf/route53.ini -ENV S6_BEHAVIOUR_IF_STAGE2_FAILS=2 CRYPTOGRAPHY_DONT_BUILD_RUST=true +ENV S6_BEHAVIOUR_IF_STAGE2_FAILS=2 RUN \ echo "**** install build packages ****" && \ diff --git a/Dockerfile.armhf b/Dockerfile.armhf index 1b194bb..681d520 100755 --- a/Dockerfile.armhf +++ b/Dockerfile.armhf @@ -9,7 +9,7 @@ LABEL maintainer="aptalca" # environment settings ENV DHLEVEL=2048 ONLY_SUBDOMAINS=false AWS_CONFIG_FILE=/config/dns-conf/route53.ini -ENV S6_BEHAVIOUR_IF_STAGE2_FAILS=2 CRYPTOGRAPHY_DONT_BUILD_RUST=true +ENV S6_BEHAVIOUR_IF_STAGE2_FAILS=2 RUN \ echo "**** install build packages ****" && \