From 70b58453ef06370f7716ee799f96cef576fa69ac Mon Sep 17 00:00:00 2001 From: Philippe Delodder Date: Mon, 16 Feb 2026 21:10:30 +0100 Subject: [PATCH 1/4] move to apt source for amd64 --- docker/Dockerfile | 12 +++++++----- docker/download-deconz.sh | 32 +++++++++++++++++++++++++++----- 2 files changed, 34 insertions(+), 10 deletions(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index a3a27c2..1ffff6b 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -89,13 +89,15 @@ RUN groupadd -g ${DECONZ_GID} "deconz" && \ # Add deCONZ, install deCONZ, make OTAU dir COPY download-deconz.sh / +RUN chmod +x /download-deconz.sh && \ + /download-deconz.sh ${VERSION} ${CHANNEL} ${TARGETPLATFORM} -RUN chmod +x /download-deconz.sh && /download-deconz.sh ${VERSION} ${CHANNEL} ${TARGETPLATFORM} - -RUN dpkg -i /deconz.deb && \ +# Conditional Install: Only run dpkg if the .deb exists (for arm64/v7) +RUN if [ -f /deconz.deb ]; then \ + dpkg -i /deconz.deb && rm /deconz.deb; \ + fi && \ chown root:root /usr/bin/deCONZ* && \ - setcap CAP_NET_BIND_SERVICE=+eip /usr/bin/deCONZ && \ - rm -f /deconz.deb + setcap CAP_NET_BIND_SERVICE=+eip /usr/bin/deCONZ VOLUME [ "/opt/deCONZ" ] diff --git a/docker/download-deconz.sh b/docker/download-deconz.sh index d67b060..4c14756 100755 --- a/docker/download-deconz.sh +++ b/docker/download-deconz.sh @@ -3,17 +3,39 @@ set -ex DECONZ_VERSION=$1 -CHANNEL=$2 +CHANNEL=$2 # stable or beta PLATFORM=$3 -if echo "${PLATFORM}" | grep -qE "arm64"; then - URL="http://deconz.dresden-elektronik.de/debian/${CHANNEL}/deconz_${DECONZ_VERSION}-debian-buster-${CHANNEL}_arm64.deb" +# Map "generic-beta" for APT if channel is beta +APT_CHANNEL="generic" +if [ "${CHANNEL}" = "beta" ]; then + APT_CHANNEL="generic-beta" fi + if echo "${PLATFORM}" | grep -qE "amd64"; then - URL="http://deconz.dresden-elektronik.de/ubuntu/${CHANNEL}/deconz-${DECONZ_VERSION}-qt5.deb" + # 1. Install Repo GPG Key + curl -sL http://phoscon.de/apt/deconz.pub.key | apt-key add - + + # 2. Add Repository + echo "deb [arch=amd64] http://phoscon.de/apt/deconz ${APT_CHANNEL} main" > /etc/apt/sources.list.d/deconz.list + + # 3. Install via APT + apt-get update + # Note: We install a specific version if provided, otherwise latest + apt-get install -y deconz="${DECONZ_VERSION}*" || apt-get install -y deconz + + # Create a dummy file so the Dockerfile dpkg command doesn't fail, + # or we can handle the logic in the Dockerfile (see below). + touch /deconz_installed_via_apt + exit 0 +fi + +# Fallback for arm64 / v7 (Manual Download) +if echo "${PLATFORM}" | grep -qE "arm64"; then + URL="http://deconz.dresden-elektronik.de/debian/${CHANNEL}/deconz_${DECONZ_VERSION}-debian-buster-${CHANNEL}_arm64.deb" fi if echo "${PLATFORM}" | grep -qE "v7"; then URL="http://deconz.dresden-elektronik.de/raspbian/${CHANNEL}/deconz-${DECONZ_VERSION}-qt5.deb" fi -curl -vv "${URL}" -o /deconz${DEV}.deb +curl -vv "${URL}" -o /deconz.deb From f65928131650d3ad773b59c3ce2124d16f4f7861 Mon Sep 17 00:00:00 2001 From: Philippe Delodder Date: Mon, 16 Feb 2026 21:16:28 +0100 Subject: [PATCH 2/4] Clean up the download script --- docker/download-deconz.sh | 36 +++++++++++++++--------------------- 1 file changed, 15 insertions(+), 21 deletions(-) diff --git a/docker/download-deconz.sh b/docker/download-deconz.sh index 4c14756..826fa93 100755 --- a/docker/download-deconz.sh +++ b/docker/download-deconz.sh @@ -3,30 +3,24 @@ set -ex DECONZ_VERSION=$1 -CHANNEL=$2 # stable or beta +CHANNEL=$2 PLATFORM=$3 -# Map "generic-beta" for APT if channel is beta -APT_CHANNEL="generic" -if [ "${CHANNEL}" = "beta" ]; then - APT_CHANNEL="generic-beta" -fi - -if echo "${PLATFORM}" | grep -qE "amd64"; then - # 1. Install Repo GPG Key - curl -sL http://phoscon.de/apt/deconz.pub.key | apt-key add - - - # 2. Add Repository - echo "deb [arch=amd64] http://phoscon.de/apt/deconz ${APT_CHANNEL} main" > /etc/apt/sources.list.d/deconz.list - - # 3. Install via APT +if [[ "$PLATFORM" == *"amd64"* ]]; then + apt-get update && apt-get install -y gnupg2 wget + + # Download key to the modern keyring location + wget -O - http://phoscon.de/apt/deconz.pub.key | gpg --dearmor -o /usr/share/keyrings/deconz.gpg + + APT_CHANNEL="generic" + if [ "$CHANNEL" == "beta" ]; then APT_CHANNEL="generic-beta"; fi + + echo "deb [arch=amd64 signed-by=/usr/share/keyrings/deconz.gpg] http://phoscon.de/apt/deconz ${APT_CHANNEL} main" > /etc/apt/sources.list.d/deconz.list + apt-get update - # Note: We install a specific version if provided, otherwise latest - apt-get install -y deconz="${DECONZ_VERSION}*" || apt-get install -y deconz - - # Create a dummy file so the Dockerfile dpkg command doesn't fail, - # or we can handle the logic in the Dockerfile (see below). - touch /deconz_installed_via_apt + apt-get install -y deconz + # Create a flag so the Dockerfile knows skip dpkg + touch /tmp/apt_installed exit 0 fi From 56717c232b230bbe3838c40af0c8d964577e6af5 Mon Sep 17 00:00:00 2001 From: Philippe Delodder Date: Mon, 16 Feb 2026 21:20:24 +0100 Subject: [PATCH 3/4] Small improvement --- docker/Dockerfile | 2 ++ docker/download-deconz.sh | 2 -- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index 1ffff6b..3cd7aee 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -41,6 +41,8 @@ ENV DEBIAN_FRONTEND=noninteractive \ # Install deCONZ dependencies RUN apt-get update && \ apt-get install -y \ + wget \ + gnupg \ gosu \ curl \ kmod \ diff --git a/docker/download-deconz.sh b/docker/download-deconz.sh index 826fa93..56ed4ff 100755 --- a/docker/download-deconz.sh +++ b/docker/download-deconz.sh @@ -7,8 +7,6 @@ CHANNEL=$2 PLATFORM=$3 if [[ "$PLATFORM" == *"amd64"* ]]; then - apt-get update && apt-get install -y gnupg2 wget - # Download key to the modern keyring location wget -O - http://phoscon.de/apt/deconz.pub.key | gpg --dearmor -o /usr/share/keyrings/deconz.gpg From 8a1e42d20869dd7ea38ec9abb6f8f9edd9edbcc5 Mon Sep 17 00:00:00 2001 From: Philippe Delodder Date: Mon, 16 Feb 2026 21:28:13 +0100 Subject: [PATCH 4/4] trigger dev-build