Skip to content

Commit

Permalink
fix for docker hub hooks, quicker build
Browse files Browse the repository at this point in the history
  • Loading branch information
john30 committed Feb 8, 2021
1 parent ed9e5a2 commit 4f7e2ea
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 12 deletions.
2 changes: 1 addition & 1 deletion ChangeLog.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# 21.2 (2021-02-07)
# 21.2 (2021-02-08)

## Bug Fixes
* fix for UDP device connection issue
Expand Down
2 changes: 1 addition & 1 deletion contrib/docker/Dockerfile.release
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ENV EBUSD_ARCH amd64
ENV EBUSD_VERSION 21.2

RUN git clone https://github.com/john30/ebusd.git /build \
&& ./make_all.sh
&& ./make_debian.sh



Expand Down
2 changes: 1 addition & 1 deletion contrib/docker/Dockerfile.release.arm32v5
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ENV EBUSD_ARCH arm32v5
ENV EBUSD_VERSION 21.2

RUN git clone https://github.com/john30/ebusd.git /build \
&& ./make_all.sh
&& ./make_debian.sh



Expand Down
2 changes: 1 addition & 1 deletion contrib/docker/Dockerfile.release.arm32v7
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ENV EBUSD_ARCH arm32v7
ENV EBUSD_VERSION 21.2

RUN git clone https://github.com/john30/ebusd.git /build \
&& ./make_all.sh
&& ./make_debian.sh



Expand Down
2 changes: 1 addition & 1 deletion contrib/docker/Dockerfile.release.arm64v8
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ENV EBUSD_ARCH arm64v8
ENV EBUSD_VERSION 21.2

RUN git clone https://github.com/john30/ebusd.git /build \
&& ./make_all.sh
&& ./make_debian.sh



Expand Down
2 changes: 1 addition & 1 deletion contrib/docker/Dockerfile.release.i386
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ENV EBUSD_ARCH i386
ENV EBUSD_VERSION 21.2

RUN git clone https://github.com/john30/ebusd.git /build \
&& ./make_all.sh
&& ./make_debian.sh



Expand Down
2 changes: 1 addition & 1 deletion contrib/docker/Dockerfile.template
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ENV EBUSD_ARCH %EBUSD_ARCH%
ENV EBUSD_VERSION %EBUSD_VERSION%

RUN git clone https://github.com/john30/ebusd.git /build \
&& %EBUSD_MAKE%
&& ./make_debian.sh

%EBUSD_UPLOAD_LINES%

Expand Down
11 changes: 6 additions & 5 deletions contrib/docker/update.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,33 +23,34 @@ function replaceTemplate () {
-e "s#%QEMU_FROM_LINE%#${qemu_from_line}#g" \
-e "s#%BASE_IMAGE%#${prefix}${BASE_IMAGE:-$DEFAULT_IMAGE}#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_VARIANT%#${version_variant}#g" \
-e "s#%EBUSD_ARCH%#${arch}#g" \
-e "s#%EXTRA_RM%#${extra_rm}#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}"
}

if [[ -z "$1" ]]; then
# devel updates
version_variant='-devel'
make='./make_debian.sh'
dir=''
upload_line=''
namesuffix=''
for arch in $archs; do
replaceTemplate
done
fi

# release updates
version_variant=''
make='./make_all.sh'
dir=${1:-release/}
dir="$1"
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'
namesuffix=''
else
namesuffix='.release'
fi
for arch in $archs; do
replaceTemplate
Expand Down

0 comments on commit 4f7e2ea

Please sign in to comment.