From 9551fc85d942e2c81873c7c09a141af8b8639261 Mon Sep 17 00:00:00 2001 From: nicomiguelino Date: Tue, 2 Apr 2024 12:15:47 -0700 Subject: [PATCH] workaround: Pull Pi 4 images when fetching Docker images for Pi 5. --- bin/install.sh | 4 ++++ bin/upgrade_containers.sh | 2 ++ 2 files changed, 6 insertions(+) diff --git a/bin/install.sh b/bin/install.sh index 954ac8815..1062b43fc 100755 --- a/bin/install.sh +++ b/bin/install.sh @@ -199,6 +199,10 @@ fi sudo ${SUDO_ARGS[@]} pip install cryptography==38.0.2 sudo ${SUDO_ARGS[@]} pip install "$ANSIBLE_VERSION" +# @TODO: Remove two lines below after testing. +export REPOSITORY='https://github.com/nicomiguelino/Anthias.git' +export BRANCH=${CUSTOM_BRANCH} + sudo -u ${USER} ${SUDO_ARGS[@]} ansible localhost \ -m git \ -a "repo=$REPOSITORY dest=/home/${USER}/screenly version=$BRANCH force=no" diff --git a/bin/upgrade_containers.sh b/bin/upgrade_containers.sh index 9bb6086ba..55ac45d3c 100755 --- a/bin/upgrade_containers.sh +++ b/bin/upgrade_containers.sh @@ -12,6 +12,8 @@ export VIEWER_MEMORY_LIMIT_KB=$(echo "$TOTAL_MEMORY_KB" \* 0.8 | bc) export DOCKER_TAG="latest" # Detect Raspberry Pi version +if grep -qF "Raspberry Pi 5" /proc/device-tree/model; then + export DEVICE_TYPE="pi4" # @TODO: Change this to "pi5" later. if grep -qF "Raspberry Pi 4" /proc/device-tree/model; then export DEVICE_TYPE="pi4" elif grep -qF "Raspberry Pi 3" /proc/device-tree/model; then