fix for docker hub hooks, quicker build

This commit is contained in:
John
2021-02-08 22:12:27 +01:00
parent ed9e5a27ad
commit 4f7e2eabfe
8 changed files with 13 additions and 12 deletions
+1 -1
View File
@@ -1,4 +1,4 @@
# 21.2 (2021-02-07) # 21.2 (2021-02-08)
## Bug Fixes ## Bug Fixes
* fix for UDP device connection issue * fix for UDP device connection issue
+1 -1
View File
@@ -13,7 +13,7 @@ ENV EBUSD_ARCH amd64
ENV EBUSD_VERSION 21.2 ENV EBUSD_VERSION 21.2
RUN git clone https://github.com/john30/ebusd.git /build \ RUN git clone https://github.com/john30/ebusd.git /build \
&& ./make_all.sh && ./make_debian.sh
+1 -1
View File
@@ -13,7 +13,7 @@ ENV EBUSD_ARCH arm32v5
ENV EBUSD_VERSION 21.2 ENV EBUSD_VERSION 21.2
RUN git clone https://github.com/john30/ebusd.git /build \ RUN git clone https://github.com/john30/ebusd.git /build \
&& ./make_all.sh && ./make_debian.sh
+1 -1
View File
@@ -13,7 +13,7 @@ ENV EBUSD_ARCH arm32v7
ENV EBUSD_VERSION 21.2 ENV EBUSD_VERSION 21.2
RUN git clone https://github.com/john30/ebusd.git /build \ RUN git clone https://github.com/john30/ebusd.git /build \
&& ./make_all.sh && ./make_debian.sh
+1 -1
View File
@@ -13,7 +13,7 @@ ENV EBUSD_ARCH arm64v8
ENV EBUSD_VERSION 21.2 ENV EBUSD_VERSION 21.2
RUN git clone https://github.com/john30/ebusd.git /build \ RUN git clone https://github.com/john30/ebusd.git /build \
&& ./make_all.sh && ./make_debian.sh
+1 -1
View File
@@ -13,7 +13,7 @@ ENV EBUSD_ARCH i386
ENV EBUSD_VERSION 21.2 ENV EBUSD_VERSION 21.2
RUN git clone https://github.com/john30/ebusd.git /build \ RUN git clone https://github.com/john30/ebusd.git /build \
&& ./make_all.sh && ./make_debian.sh
+1 -1
View File
@@ -13,7 +13,7 @@ ENV EBUSD_ARCH %EBUSD_ARCH%
ENV EBUSD_VERSION %EBUSD_VERSION% ENV EBUSD_VERSION %EBUSD_VERSION%
RUN git clone https://github.com/john30/ebusd.git /build \ RUN git clone https://github.com/john30/ebusd.git /build \
&& %EBUSD_MAKE% && ./make_debian.sh
%EBUSD_UPLOAD_LINES% %EBUSD_UPLOAD_LINES%
+6 -5
View File
@@ -23,22 +23,21 @@ function replaceTemplate () {
-e "s#%QEMU_FROM_LINE%#${qemu_from_line}#g" \ -e "s#%QEMU_FROM_LINE%#${qemu_from_line}#g" \
-e "s#%BASE_IMAGE%#${prefix}${BASE_IMAGE:-$DEFAULT_IMAGE}#g" \ -e "s#%BASE_IMAGE%#${prefix}${BASE_IMAGE:-$DEFAULT_IMAGE}#g" \
-e "s#%QEMU_FROM_COPY%#${qemu_from_copy}#g" \ -e "s#%QEMU_FROM_COPY%#${qemu_from_copy}#g" \
-e "s#%EBUSD_MAKE%#${make}#g" \
-e "s#%EBUSD_VERSION%#${EBUSD_VERSION}#g" \ -e "s#%EBUSD_VERSION%#${EBUSD_VERSION}#g" \
-e "s#%EBUSD_VERSION_VARIANT%#${version_variant}#g" \ -e "s#%EBUSD_VERSION_VARIANT%#${version_variant}#g" \
-e "s#%EBUSD_ARCH%#${arch}#g" \ -e "s#%EBUSD_ARCH%#${arch}#g" \
-e "s#%EXTRA_RM%#${extra_rm}#g" \ -e "s#%EXTRA_RM%#${extra_rm}#g" \
-e "s#%EBUSD_UPLOAD_LINES%#${upload_lines}#g" \ -e "s#%EBUSD_UPLOAD_LINES%#${upload_lines}#g" \
Dockerfile.template > "${dir}Dockerfile${suffix}" Dockerfile.template > "${dir}Dockerfile${namesuffix}${suffix}"
echo "updated ${dir}Dockerfile${suffix}" echo "updated ${dir}Dockerfile${suffix}"
} }
if [[ -z "$1" ]]; then if [[ -z "$1" ]]; then
# devel updates # devel updates
version_variant='-devel' version_variant='-devel'
make='./make_debian.sh'
dir='' dir=''
upload_line='' upload_line=''
namesuffix=''
for arch in $archs; do for arch in $archs; do
replaceTemplate replaceTemplate
done done
@@ -46,10 +45,12 @@ fi
# release updates # release updates
version_variant='' version_variant=''
make='./make_all.sh' dir="$1"
dir=${1:-release/}
if [[ -n "$1" ]]; then if [[ -n "$1" ]]; then
upload_lines='ARG UPLOAD_URL\nARG UPLOAD_CREDENTIALS\nARG UPLOAD_OS\nRUN if [ -n "\$UPLOAD_URL" ] \&\& [ -n "\$UPLOAD_CREDENTIALS" ]; then for img in ebusd-*.deb; do echo -n "upload \$img: "; curl -fs -u "\$UPLOAD_CREDENTIALS" -X POST --data-binary "@\$img" -H "Content-Type: application/octet-stream" "\$UPLOAD_URL/\$img?a=\$EBUSD_ARCH\&o=\$UPLOAD_OS\&v=\$EBUSD_VERSION" || echo "failed"; done; fi' upload_lines='ARG UPLOAD_URL\nARG UPLOAD_CREDENTIALS\nARG UPLOAD_OS\nRUN if [ -n "\$UPLOAD_URL" ] \&\& [ -n "\$UPLOAD_CREDENTIALS" ]; then for img in ebusd-*.deb; do echo -n "upload \$img: "; curl -fs -u "\$UPLOAD_CREDENTIALS" -X POST --data-binary "@\$img" -H "Content-Type: application/octet-stream" "\$UPLOAD_URL/\$img?a=\$EBUSD_ARCH\&o=\$UPLOAD_OS\&v=\$EBUSD_VERSION" || echo "failed"; done; fi'
namesuffix=''
else
namesuffix='.release'
fi fi
for arch in $archs; do for arch in $archs; do
replaceTemplate replaceTemplate