Skip to content
Snippets Groups Projects
Commit 0eef6515 authored by Your Name's avatar Your Name Committed by Konstantin Pavlov
Browse files

Updated nginx versions to current

While at it, introduced specific env variables for built-in dynamic
modules versions, as they can differ from the main nginx binary
packages.
parent a6f7d140
No related branches found
No related tags found
No related merge requests found
...@@ -4,6 +4,7 @@ LABEL maintainer="NGINX Docker Maintainers <docker-maint@nginx.com>" ...@@ -4,6 +4,7 @@ LABEL maintainer="NGINX Docker Maintainers <docker-maint@nginx.com>"
ENV NGINX_VERSION %%NGINX_VERSION%% ENV NGINX_VERSION %%NGINX_VERSION%%
ENV PKG_RELEASE %%PKG_RELEASE%% ENV PKG_RELEASE %%PKG_RELEASE%%
ENV DYNPKG_RELEASE %%DYNPKG_RELEASE%%
RUN set -x \ RUN set -x \
# create nginx user/group first, to be consistent throughout docker variants # create nginx user/group first, to be consistent throughout docker variants
......
...@@ -6,6 +6,7 @@ ENV NGINX_VERSION %%NGINX_VERSION%% ...@@ -6,6 +6,7 @@ ENV NGINX_VERSION %%NGINX_VERSION%%
ENV NJS_VERSION %%NJS_VERSION%% ENV NJS_VERSION %%NJS_VERSION%%
ENV NJS_RELEASE %%NJS_RELEASE%% ENV NJS_RELEASE %%NJS_RELEASE%%
ENV PKG_RELEASE %%PKG_RELEASE%% ENV PKG_RELEASE %%PKG_RELEASE%%
ENV DYNPKG_RELEASE %%DYNPKG_RELEASE%%
RUN set -x \ RUN set -x \
# create nginx user/group first, to be consistent throughout docker variants # create nginx user/group first, to be consistent throughout docker variants
......
...@@ -12,21 +12,21 @@ declare branches=( ...@@ -12,21 +12,21 @@ declare branches=(
# Current nginx versions # Current nginx versions
# Remember to update pkgosschecksum when changing this. # Remember to update pkgosschecksum when changing this.
declare -A nginx=( declare -A nginx=(
[mainline]='1.27.0' [mainline]='1.27.1'
[stable]='1.26.1' [stable]='1.26.2'
) )
# Current njs versions # Current njs versions
declare -A njs=( declare -A njs=(
[mainline]='0.8.4' [mainline]='0.8.5'
[stable]='0.8.4' [stable]='0.8.5'
) )
# Current njs patchlevel version # Current njs patchlevel version
# Remember to update pkgosschecksum when changing this. # Remember to update pkgosschecksum when changing this.
declare -A njspkg=( declare -A njspkg=(
[mainline]='2' [mainline]='1'
[stable]='2' [stable]='1'
) )
# Current otel versions # Current otel versions
...@@ -35,9 +35,16 @@ declare -A otel=( ...@@ -35,9 +35,16 @@ declare -A otel=(
[stable]='0.1.0' [stable]='0.1.0'
) )
# Current package patchlevel version # Current nginx package patchlevel version
# Remember to update pkgosschecksum when changing this. # Remember to update pkgosschecksum when changing this.
declare -A pkg=( declare -A pkg=(
[mainline]=1
[stable]=1
)
# Current built-in dynamic modules package patchlevel version
# Remember to update pkgosschecksum when changing this
declare -A dynpkg=(
[mainline]=2 [mainline]=2
[stable]=2 [stable]=2
) )
...@@ -65,8 +72,8 @@ declare -A rev=( ...@@ -65,8 +72,8 @@ declare -A rev=(
# revision/tag in the previous block # revision/tag in the previous block
# Used in alpine builds for architectures not packaged by nginx.org # Used in alpine builds for architectures not packaged by nginx.org
declare -A pkgosschecksum=( declare -A pkgosschecksum=(
[mainline]='cd3333f4dfa4a873f6df73dfe24e047adc092d779aefb46577b6307ff0d0125543508694a80158b2bfc891167ad763b0d08287829df9924d4c22f50d063e76c0' [mainline]='b9fbdf1779186fc02aa59dd87597fe4e906892391614289a4e6eedba398a3e770347b5b07110cca8c11fa3ba85bb711626ae69832e74c69ca8340d040a465907'
[stable]='0db2bf5f86e7c31f23d0e3e7699a5d8a4d9d9b0dc2f98d3e3a31e004df20206270debf6502e4481892e8b64d55fba73fcc8d74c3e0ddfcd2d3f85a17fa02a25e' [stable]='825f610c44dfb97166112e6d060c0ba209a74f50e42c7c23a5b8742f468596f110bb1b4ca9299547a8a3d41f3a7caa864622f40f6c7bb4d8bab3d24880bdfb6a'
) )
get_packages() { get_packages() {
...@@ -108,9 +115,12 @@ get_packages() { ...@@ -108,9 +115,12 @@ get_packages() {
done done
;; ;;
*) *)
for p in nginx nginx-module-xslt nginx-module-geoip nginx-module-image-filter $perl; do for p in nginx; do
echo -n ' '"$p"'=${NGINX_VERSION}-'"$r"'${PKG_RELEASE} \\\n' echo -n ' '"$p"'=${NGINX_VERSION}-'"$r"'${PKG_RELEASE} \\\n'
done done
for p in nginx-module-xslt nginx-module-geoip nginx-module-image-filter $perl; do
echo -n ' '"$p"'=${NGINX_VERSION}-'"$r"'${DYNPKG_RELEASE} \\\n'
done
for p in nginx-module-njs; do for p in nginx-module-njs; do
echo -n ' '"$p"'=${NGINX_VERSION}'"$sep"'${NJS_VERSION}-'"$r"'${NJS_RELEASE} \\'"$bn" echo -n ' '"$p"'=${NGINX_VERSION}'"$sep"'${NJS_VERSION}-'"$r"'${NJS_RELEASE} \\'"$bn"
done done
...@@ -149,7 +159,17 @@ get_packagever() { ...@@ -149,7 +159,17 @@ get_packagever() {
[ "${distro}" = "debian" ] && suffix="~${debianver}" [ "${distro}" = "debian" ] && suffix="~${debianver}"
[ "${package}" = "njs" ] && echo ${njspkg[$branch]}${suffix} || echo ${pkg[$branch]}${suffix} case "${package}" in
"njs")
echo ${njspkg[$branch]}${suffix}
;;
"dyn")
echo ${dynpkg[$branch]}${suffix}
;;
*)
echo ${pkg[$branch]}${suffix}
;;
esac
} }
get_buildtarget() { get_buildtarget() {
...@@ -172,7 +192,7 @@ get_buildtarget() { ...@@ -172,7 +192,7 @@ get_buildtarget() {
echo "\$nginxPackages" echo "\$nginxPackages"
;; ;;
debian-perl) debian-perl)
echo "nginx-module-perl=\${NGINX_VERSION}-\${PKG_RELEASE}" echo "nginx-module-perl=\${NGINX_VERSION}-\${DYNPKG_RELEASE}"
;; ;;
debian-otel) debian-otel)
echo "nginx-module-otel" echo "nginx-module-otel"
...@@ -218,11 +238,13 @@ for branch in "${branches[@]}"; do ...@@ -218,11 +238,13 @@ for branch in "${branches[@]}"; do
packages=$(get_packages "$variant" "$branch") packages=$(get_packages "$variant" "$branch")
packagever=$(get_packagever "$variant" "$branch" "any") packagever=$(get_packagever "$variant" "$branch" "any")
njspkgver=$(get_packagever "$variant" "$branch" "njs") njspkgver=$(get_packagever "$variant" "$branch" "njs")
dynpkgver=$(get_packagever "$variant" "$branch" "dyn")
buildtarget=$(get_buildtarget "$variant") buildtarget=$(get_buildtarget "$variant")
sed -i.bak \ sed -i.bak \
-e 's,%%ALPINE_VERSION%%,'"$alpinever"',' \ -e 's,%%ALPINE_VERSION%%,'"$alpinever"',' \
-e 's,%%DEBIAN_VERSION%%,'"$debianver"',' \ -e 's,%%DEBIAN_VERSION%%,'"$debianver"',' \
-e 's,%%DYNPKG_RELEASE%%,'"$dynpkgver"',' \
-e 's,%%NGINX_VERSION%%,'"$nginxver"',' \ -e 's,%%NGINX_VERSION%%,'"$nginxver"',' \
-e 's,%%NJS_VERSION%%,'"$njsver"',' \ -e 's,%%NJS_VERSION%%,'"$njsver"',' \
-e 's,%%NJS_RELEASE%%,'"$njspkgver"',' \ -e 's,%%NJS_RELEASE%%,'"$njspkgver"',' \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment